Search in sources :

Example 11 with PojoConfigSource

use of org.apache.maven.plugins.assembly.testutils.PojoConfigSource in project maven-plugins by apache.

the class ReaderFormatterTest method lineDosFeed.

@Test
public void lineDosFeed() throws IOException, AssemblyFormattingException {
    final PojoConfigSource cfg = getPojoConfigSource();
    InputStreamTransformer fileSetTransformers = ReaderFormatter.getFileSetTransformers(cfg, true, "dos");
    InputStream fud = fileSetTransformers.transform(dummyResource(), payload("This is a\ntest."));
    assertEquals("This is a\r\ntest.", readResultStream(fud));
}
Also used : ByteArrayInputStream(java.io.ByteArrayInputStream) InputStream(java.io.InputStream) InputStreamTransformer(org.codehaus.plexus.components.io.functions.InputStreamTransformer) PojoConfigSource(org.apache.maven.plugins.assembly.testutils.PojoConfigSource) Test(org.junit.Test)

Aggregations

PojoConfigSource (org.apache.maven.plugins.assembly.testutils.PojoConfigSource)11 Model (org.apache.maven.model.Model)7 Assembly (org.apache.maven.plugins.assembly.model.Assembly)7 MavenProject (org.apache.maven.project.MavenProject)7 ByteArrayInputStream (java.io.ByteArrayInputStream)3 InputStream (java.io.InputStream)3 InputStreamTransformer (org.codehaus.plexus.components.io.functions.InputStreamTransformer)3 Test (org.junit.Test)3 Properties (java.util.Properties)2 DependencySet (org.apache.maven.plugins.assembly.model.DependencySet)2 ArtifactRepository (org.apache.maven.artifact.repository.ArtifactRepository)1 MavenSession (org.apache.maven.execution.MavenSession)1 Build (org.apache.maven.model.Build)1 DefaultMavenReaderFilter (org.apache.maven.shared.filtering.DefaultMavenReaderFilter)1 PropertiesBasedValueSource (org.codehaus.plexus.interpolation.fixed.PropertiesBasedValueSource)1 ConsoleLogger (org.codehaus.plexus.logging.console.ConsoleLogger)1 EasyMockSupport (org.easymock.classextension.EasyMockSupport)1