Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MNG-7285] - Test showcasing regression #570

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -43,6 +43,8 @@
import org.apache.maven.shared.utils.io.FileUtils;


import junit.framework.TestResult;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

where is used?


public class ProjectBuilderTest
extends AbstractCoreMavenComponentTestCase
{
Expand Down Expand Up @@ -119,6 +121,18 @@ public void testResolveDependencies()
assertEquals( 1, results.size() );
MavenProject mavenProject = results.get( 0 ).getProject();
assertEquals( 1, mavenProject.getArtifacts().size() );

final MavenProject project = mavenProject;
final int[] getArtifactsResultInAnotherThead = { 0 };
Thread t = new Thread(new Runnable() {
@Override
public void run() {
getArtifactsResultInAnotherThead[0] = project.getArtifacts().size();
}
});
t.start();
t.join();
assertEquals( project.getArtifacts().size(), getArtifactsResultInAnotherThead[0] );
}

public void testDontResolveDependencies()
Expand Down