Package org.gradle.api.internal.artifacts.publish

Examples of org.gradle.api.internal.artifacts.publish.DefaultPublishArtifact


        }});
        return configurationStub;
    }

    private PublishArtifact createNamedPublishArtifact(String name) {
        return new DefaultPublishArtifact(name, "ext", "type", "classifier", new Date(), new File("somePath"));
    }
View Full Code Here


        final Task otherConfTaskMock = context.mock(Task.class, "otherConfTask");
        final Task artifactTaskMock = context.mock(Task.class, "artifactTask");
        final Configuration otherConfiguration = context.mock(Configuration.class);
        final TaskDependency otherConfTaskDependencyMock = context.mock(TaskDependency.class, "otherConfTaskDep");
        final TaskDependency artifactTaskDependencyMock = context.mock(TaskDependency.class, "artifactTaskDep");
        DefaultPublishArtifact artifact = HelperUtil.createPublishArtifact("name1", "ext1", "type1", "classifier1");
        artifact.setTaskDependency(artifactTaskDependencyMock);
        configuration.addArtifact(artifact);

        context.checking(new Expectations() {{
            allowing(otherConfiguration).getBuildArtifacts();
            will(returnValue(otherConfTaskDependencyMock));
View Full Code Here

        checkTransaction(testDefaultMavenDeployments, attachedArtifact, classifierArtifact);
        assertSame(mavenSettingsMock, getMavenResolver().getSettings());
    }

    private PublishArtifact artifact(File file) {
        return new DefaultPublishArtifact("name", "ext", "type", null, null, file);
    }
View Full Code Here

        final Task artifactTaskMock = context.mock(Task.class, "artifactTask");
        final Configuration otherConfiguration = context.mock(Configuration.class);
        final TaskDependency otherArtifactTaskDependencyMock = context.mock(TaskDependency.class, "otherConfTaskDep");
        final PublishArtifact otherArtifact = context.mock(PublishArtifact.class, "otherArtifact");
        final PublishArtifactSet inheritedArtifacts = new DefaultPublishArtifactSet("artifacts", toDomainObjectSet(PublishArtifact.class, otherArtifact));
        DefaultPublishArtifact artifact = createPublishArtifact("name1", "ext1", "type1", "classifier1");
        artifact.builtBy(artifactTaskMock);
        configuration.getArtifacts().add(artifact);

        context.checking(new Expectations() {{
            allowing(otherConfiguration).getHierarchy();
            will(returnValue(toSet()));
View Full Code Here

    ModuleDependency createDependency(String group, String name, String version) {
        return new DefaultExternalModuleDependency(group, name, version);
    }

    DefaultPublishArtifact createPublishArtifact(String name, String extension, String type, String classifier) {
        return new DefaultPublishArtifact(name, extension, type, classifier, new Date(), new File(""));
    }
View Full Code Here

TOP

Related Classes of org.gradle.api.internal.artifacts.publish.DefaultPublishArtifact

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.