test_class.file: buildergen/src/test/java/info/piwai/buildergen/generation/ResourceCodeWriterTest.java
test_class.identifier: ResourceCodeWriterTest
test_case.body: @Test
  	public void usesFilerToOpenStream() throws IOException {
  
  		Filer filer = mock(Filer.class);
  		FileObject fileObject = mock(FileObject.class);
  		when(filer.createResource(Mockito.<Location> any(), anyString(), anyString())).thenReturn(fileObject);
  
  		OutputStream expectedOS = mock(OutputStream.class);
  		when(fileObject.openOutputStream()).thenReturn(expectedOS);
  
  		ResourceCodeWriter resourceCodeWriter = new ResourceCodeWriter(filer);
  		JPackage jPackage = new JCodeModel()._package("some.package");
  		OutputStream resultingOS = resourceCodeWriter.openBinary(jPackage, null);
  
  		assertSame(expectedOS, resultingOS);
  	}
test_case.class_method_signature: ResourceCodeWriterTest.usesFilerToOpenStream()
test_case.full_signature: @Test public void usesFilerToOpenStream()
test_case.identifier: usesFilerToOpenStream
test_case.invocations: mock mock thenReturn when createResource any anyString anyString mock thenReturn when openOutputStream _package openBinary assertSame
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void usesFilerToOpenStream()
focal_class.declarator: filer
focal_class.modifier: private final
focal_class.original_string: private final Filer filer;
focal_class.type: Filer
focal_class.var_name: filer
focal_class.file: buildergen/src/main/java/info/piwai/buildergen/generation/ResourceCodeWriter.java
focal_class.identifier: ResourceCodeWriter
focal_class.class_method_signature: ResourceCodeWriter.ResourceCodeWriter(Filer filer)
focal_class.full_signature: public  ResourceCodeWriter(Filer filer)
focal_class.identifier: ResourceCodeWriter
focal_class.modifiers: public
focal_class.parameters: (Filer filer)
focal_class.signature:  ResourceCodeWriter(Filer filer)
focal_class.class_method_signature: ResourceCodeWriter.openBinary(JPackage pkg, String fileName)
focal_class.full_signature: @Override public OutputStream openBinary(JPackage pkg, String fileName)
focal_class.identifier: openBinary
focal_class.modifiers: @Override public
focal_class.parameters: (JPackage pkg, String fileName)
focal_class.return: OutputStream
focal_class.signature: OutputStream openBinary(JPackage pkg, String fileName)
focal_class.class_method_signature: ResourceCodeWriter.close()
focal_class.full_signature: @Override public void close()
focal_class.identifier: close
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void close()
focal_class.superclass: extends CodeWriter
focal_method.body: @Override
  	public OutputStream openBinary(JPackage pkg, String fileName) throws IOException {
  		FileObject resource = filer.createResource(StandardLocation.SOURCE_OUTPUT, pkg.name(), fileName);
  		return resource.openOutputStream();
  	}
focal_method.class_method_signature: ResourceCodeWriter.openBinary(JPackage pkg, String fileName)
focal_method.full_signature: @Override public OutputStream openBinary(JPackage pkg, String fileName)
focal_method.identifier: openBinary
focal_method.invocations: createResource name openOutputStream
focal_method.modifiers: @Override public
focal_method.parameters: (JPackage pkg, String fileName)
focal_method.return: OutputStream
focal_method.signature: OutputStream openBinary(JPackage pkg, String fileName)