Re: [GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-08-29 Thread Tibor Digana
I mean to reorganize the control flow in to this order which should work
for both of us:

1.

List dependenciesToScan =
DependencyScanner.filter( project.getTestArtifacts(),
Arrays.asList( getDependenciesToScan() ) );
DependencyScanner scanner = new DependencyScanner( dependenciesToScan,
getIncludedAndExcludedTests() );
scanner.scan(); // !!! not to return yet !!!

2.

for ( MavenProject mavenProject : session.getSortedProjects() )
{

IF groupId:artifactId IS NOT IN project.getTestArtifacts() THEN =>
additionally scan it and aggregate in to one single result

}








On Tue, Aug 29, 2017 at 2:48 PM, owenfarrell  wrote:

> Github user owenfarrell commented on a diff in the pull request:
>
> https://github.com/apache/maven-surefire/pull/157#
> discussion_r135778722
>
> --- Diff: maven-surefire-common/src/main/java/org/apache/maven/
> plugin/surefire/AbstractSurefireMojo.java ---
> @@ -847,12 +847,31 @@ private DefaultScanResult scanDependencies()
>  {
>  try
>  {
> +DefaultScanResult scanResult = new DefaultScanResult(
> Collections.EMPTY_LIST );
> +
> +List dependenciesToScan = new ArrayList();
> +Collections.addAll( dependenciesToScan,
> getDependenciesToScan() );
> +TestListResolver includedAndExcludedTests =
> getIncludedAndExcludedTests();
> +
> +for ( MavenProject mavenProject :
> session.getSortedProjects() )
> +{
> +String groupArtifactId =
> mavenProject.getGroupId() + ":" + mavenProject.getArtifactId();
> +if ( dependenciesToScan.removeAll(
> Collections.singleton( groupArtifactId ) ) )
> +{
> +File outputDirectoryFile = new File(
> mavenProject.getBuild().getOutputDirectory() );
> +DirectoryScanner scanner =
> +new DirectoryScanner(
> outputDirectoryFile, includedAndExcludedTests );
> +scanResult = scanResult.append(
> scanner.scan() );
> +}
> +}
> +
>  // @TODO noinspection unchecked, check MavenProject
> 3.x for Generics in surefire:3.0
>  @SuppressWarnings( "unchecked" )
> -List dependenciesToScan =
> -DependencyScanner.filter(
> project.getTestArtifacts(), Arrays.asList( getDependenciesToScan() ) );
> -DependencyScanner scanner = new DependencyScanner(
> dependenciesToScan, getIncludedAndExcludedTests() );
> -return scanner.scan();
> +List dependenciesToScanFile =
> +DependencyScanner.filter(
> project.getTestArtifacts(), dependenciesToScan );
> --- End diff --
>
> Locally staged updates to reflect your generics comments. But I don't
> follow what you're asking for here.
>
> [Per the documentation](https://maven.apache.org/surefire/maven-
> surefire-plugin/test-mojo.html#dependenciesToScan), the
> dependenciesToScan property doesn't support classifiers - just group ID and
> artifact ID. So I didn't add any logic around classifier resolution. Is
> that what you were expecting?
>
>
> ---
> If your project is set up for it, you can reply to this email and have your
> reply appear on GitHub as well. If your project does not have this feature
> enabled and wishes so, or if the feature is enabled but not working, please
> contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
> with INFRA.
> ---
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
> For additional commands, e-mail: dev-h...@maven.apache.org
>
>


-- 
Cheers
Tibor


Re: [GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-08-29 Thread Tibor Digana
This supports classifiers

project.getTestArtifacts()

If you find the one Artifact in this collection then you can simply ignore
it in

session.getSortedProjects()

If it basically opposite what you have done in your code with the removal.
So the old code says to take test dependencies match them with
dependenciesToScan. This is ok and after this we put more those which are
not in dependencies section but appear in depedenciesToScan as project
artifacts.


On Tue, Aug 29, 2017 at 2:48 PM, owenfarrell  wrote:

> Github user owenfarrell commented on a diff in the pull request:
>
> https://github.com/apache/maven-surefire/pull/157#
> discussion_r135778722
>
> --- Diff: maven-surefire-common/src/main/java/org/apache/maven/
> plugin/surefire/AbstractSurefireMojo.java ---
> @@ -847,12 +847,31 @@ private DefaultScanResult scanDependencies()
>  {
>  try
>  {
> +DefaultScanResult scanResult = new DefaultScanResult(
> Collections.EMPTY_LIST );
> +
> +List dependenciesToScan = new ArrayList();
> +Collections.addAll( dependenciesToScan,
> getDependenciesToScan() );
> +TestListResolver includedAndExcludedTests =
> getIncludedAndExcludedTests();
> +
> +for ( MavenProject mavenProject :
> session.getSortedProjects() )
> +{
> +String groupArtifactId =
> mavenProject.getGroupId() + ":" + mavenProject.getArtifactId();
> +if ( dependenciesToScan.removeAll(
> Collections.singleton( groupArtifactId ) ) )
> +{
> +File outputDirectoryFile = new File(
> mavenProject.getBuild().getOutputDirectory() );
> +DirectoryScanner scanner =
> +new DirectoryScanner(
> outputDirectoryFile, includedAndExcludedTests );
> +scanResult = scanResult.append(
> scanner.scan() );
> +}
> +}
> +
>  // @TODO noinspection unchecked, check MavenProject
> 3.x for Generics in surefire:3.0
>  @SuppressWarnings( "unchecked" )
> -List dependenciesToScan =
> -DependencyScanner.filter(
> project.getTestArtifacts(), Arrays.asList( getDependenciesToScan() ) );
> -DependencyScanner scanner = new DependencyScanner(
> dependenciesToScan, getIncludedAndExcludedTests() );
> -return scanner.scan();
> +List dependenciesToScanFile =
> +DependencyScanner.filter(
> project.getTestArtifacts(), dependenciesToScan );
> --- End diff --
>
> Locally staged updates to reflect your generics comments. But I don't
> follow what you're asking for here.
>
> [Per the documentation](https://maven.apache.org/surefire/maven-
> surefire-plugin/test-mojo.html#dependenciesToScan), the
> dependenciesToScan property doesn't support classifiers - just group ID and
> artifact ID. So I didn't add any logic around classifier resolution. Is
> that what you were expecting?
>
>
> ---
> If your project is set up for it, you can reply to this email and have your
> reply appear on GitHub as well. If your project does not have this feature
> enabled and wishes so, or if the feature is enabled but not working, please
> contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
> with INFRA.
> ---
>
> -
> To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
> For additional commands, e-mail: dev-h...@maven.apache.org
>
>


-- 
Cheers
Tibor


[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-08-29 Thread owenfarrell
Github user owenfarrell commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r135778722
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,31 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScan = new ArrayList();
+Collections.addAll( dependenciesToScan, 
getDependenciesToScan() );
+TestListResolver includedAndExcludedTests = 
getIncludedAndExcludedTests();
+
+for ( MavenProject mavenProject : 
session.getSortedProjects() )
+{
+String groupArtifactId = mavenProject.getGroupId() + 
":" + mavenProject.getArtifactId();
+if ( dependenciesToScan.removeAll( 
Collections.singleton( groupArtifactId ) ) )
+{
+File outputDirectoryFile = new File( 
mavenProject.getBuild().getOutputDirectory() );
+DirectoryScanner scanner =
+new DirectoryScanner( outputDirectoryFile, 
includedAndExcludedTests );
+scanResult = scanResult.append( scanner.scan() );
+}
+}
+
 // @TODO noinspection unchecked, check MavenProject 3.x 
for Generics in surefire:3.0
 @SuppressWarnings( "unchecked" )
-List dependenciesToScan =
-DependencyScanner.filter( project.getTestArtifacts(), 
Arrays.asList( getDependenciesToScan() ) );
-DependencyScanner scanner = new DependencyScanner( 
dependenciesToScan, getIncludedAndExcludedTests() );
-return scanner.scan();
+List dependenciesToScanFile =
+DependencyScanner.filter( 
project.getTestArtifacts(), dependenciesToScan );
--- End diff --

Locally staged updates to reflect your generics comments. But I don't 
follow what you're asking for here.

[Per the 
documentation](https://maven.apache.org/surefire/maven-surefire-plugin/test-mojo.html#dependenciesToScan),
 the dependenciesToScan property doesn't support classifiers - just group ID 
and artifact ID. So I didn't add any logic around classifier resolution. Is 
that what you were expecting?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-08-29 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r135766258
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,31 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScan = new ArrayList();
+Collections.addAll( dependenciesToScan, 
getDependenciesToScan() );
+TestListResolver includedAndExcludedTests = 
getIncludedAndExcludedTests();
+
+for ( MavenProject mavenProject : 
session.getSortedProjects() )
+{
+String groupArtifactId = mavenProject.getGroupId() + 
":" + mavenProject.getArtifactId();
+if ( dependenciesToScan.removeAll( 
Collections.singleton( groupArtifactId ) ) )
+{
+File outputDirectoryFile = new File( 
mavenProject.getBuild().getOutputDirectory() );
+DirectoryScanner scanner =
+new DirectoryScanner( outputDirectoryFile, 
includedAndExcludedTests );
+scanResult = scanResult.append( scanner.scan() );
+}
+}
+
 // @TODO noinspection unchecked, check MavenProject 3.x 
for Generics in surefire:3.0
 @SuppressWarnings( "unchecked" )
-List dependenciesToScan =
-DependencyScanner.filter( project.getTestArtifacts(), 
Arrays.asList( getDependenciesToScan() ) );
-DependencyScanner scanner = new DependencyScanner( 
dependenciesToScan, getIncludedAndExcludedTests() );
-return scanner.scan();
+List dependenciesToScanFile =
+DependencyScanner.filter( 
project.getTestArtifacts(), dependenciesToScan );
--- End diff --

Here some artifacts may have classifier `tests`. This means your loop may 
appear below test artifacts and only those project artifacts (gid:aid:*) should 
be excluded which appear in `getTestArtifacts()` and scans appended creating 
one aggregated scan result.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-08-29 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r135765515
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,31 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScan = new ArrayList();
+Collections.addAll( dependenciesToScan, 
getDependenciesToScan() );
+TestListResolver includedAndExcludedTests = 
getIncludedAndExcludedTests();
+
+for ( MavenProject mavenProject : 
session.getSortedProjects() )
+{
+String groupArtifactId = mavenProject.getGroupId() + 
":" + mavenProject.getArtifactId();
+if ( dependenciesToScan.removeAll( 
Collections.singleton( groupArtifactId ) ) )
+{
+File outputDirectoryFile = new File( 
mavenProject.getBuild().getOutputDirectory() );
+DirectoryScanner scanner =
+new DirectoryScanner( outputDirectoryFile, 
includedAndExcludedTests );
+scanResult = scanResult.append( scanner.scan() );
+}
+}
+
 // @TODO noinspection unchecked, check MavenProject 3.x 
for Generics in surefire:3.0
 @SuppressWarnings( "unchecked" )
-List dependenciesToScan =
-DependencyScanner.filter( project.getTestArtifacts(), 
Arrays.asList( getDependenciesToScan() ) );
-DependencyScanner scanner = new DependencyScanner( 
dependenciesToScan, getIncludedAndExcludedTests() );
-return scanner.scan();
+List dependenciesToScanFile =
--- End diff --

Pls align to single line after using static import:
`import static java.lang.Thread.currentThread;
import static 
org.apache.maven.plugin.surefire.util.DependencyScanner.filter;
import static java.util.Collections.singletonMap;`


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-08-29 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r135765205
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,31 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScan = new ArrayList();
--- End diff --

missing Generics on constructor. We have Java 1.6.
`List dependenciesToScan = new ArrayList();`



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-08-29 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r135765053
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,31 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
--- End diff --

Do you use IntelliJ IDEA? It highlights the argument in yellow.
Use this:
`DefaultScanResult scanResult = new DefaultScanResult( 
Collections.emptyList() );`


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-07-25 Thread owenfarrell
GitHub user owenfarrell reopened a pull request:

https://github.com/apache/maven-surefire/pull/157

SUREFIRE-1383 dependenciesToScan Does Not Leverage Classpath Elements

Added logic to prefer output directories of projects built as part of the 
current session.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/owenfarrell/maven-surefire master

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/maven-surefire/pull/157.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #157


commit ee3b5be037c70d2a4667d786d4c487cf89ebfdfa
Author: Owen Farrell 
Date:   2017-07-26T02:30:52Z

SUREFIRE-1383: Added logic to use build output directories for session 
projects in favor of installed artifacts




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-07-25 Thread owenfarrell
Github user owenfarrell closed the pull request at:

https://github.com/apache/maven-surefire/pull/157


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-07-01 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r125169778
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,33 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScanList = new ArrayList( 
Arrays.asList( getDependenciesToScan() ) );
--- End diff --

No need to create two collections with 
`List dependenciesToScanList = new ArrayList( Arrays.asList( 
getDependenciesToScan() ) );`
One modifiable collection can be with this code:
`List dependenciesToScanList = new ArrayList();`
`Collections.addAll( dependenciesToScanList, getDependenciesToScan() );`


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-07-01 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r125169703
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,33 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScanList = new ArrayList( 
Arrays.asList( getDependenciesToScan() ) );
+TestListResolver includedAndExcludedTests = 
getIncludedAndExcludedTests();
+
+for ( MavenProject mavenProject : 
session.getSortedProjects() )
+{
+String groupArtifactId = new StringBuilder( 
mavenProject.getGroupId() ).append( ":" )
+.append( mavenProject.getArtifactId() 
).toString();
+if ( dependenciesToScanList.removeAll( 
Collections.singleton( groupArtifactId ) ) )
+{
+File outputDirectoryFile = new File( 
mavenProject.getBuild().getOutputDirectory() );
+DirectoryScanner scanner =
+new DirectoryScanner( outputDirectoryFile, 
includedAndExcludedTests );
+scanResult = scanResult.append( scanner.scan() );
+}
+
+}
+
 // @TODO noinspection unchecked, check MavenProject 3.x 
for Generics in surefire:3.0
 @SuppressWarnings( "unchecked" )
-List dependenciesToScan =
-DependencyScanner.filter( project.getTestArtifacts(), 
Arrays.asList( getDependenciesToScan() ) );
-DependencyScanner scanner = new DependencyScanner( 
dependenciesToScan, getIncludedAndExcludedTests() );
-return scanner.scan();
+List dependenciesToScanFileList =
--- End diff --

`dependenciesToScanFileList` already contains plural. Pls rename 
`dependenciesToScanFileList` to `dependenciesToScanFile`.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-07-01 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r125169693
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,33 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScanList = new ArrayList( 
Arrays.asList( getDependenciesToScan() ) );
--- End diff --

`dependenciesToScanList` already contains plural. Pls rename 
`dependenciesToScanList` to `dependenciesToScan`.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-07-01 Thread Tibor17
Github user Tibor17 commented on a diff in the pull request:

https://github.com/apache/maven-surefire/pull/157#discussion_r125169671
  
--- Diff: 
maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
 ---
@@ -847,12 +847,33 @@ private DefaultScanResult scanDependencies()
 {
 try
 {
+DefaultScanResult scanResult = new DefaultScanResult( 
Collections.EMPTY_LIST );
+
+List dependenciesToScanList = new ArrayList( 
Arrays.asList( getDependenciesToScan() ) );
+TestListResolver includedAndExcludedTests = 
getIncludedAndExcludedTests();
+
+for ( MavenProject mavenProject : 
session.getSortedProjects() )
+{
+String groupArtifactId = new StringBuilder( 
mavenProject.getGroupId() ).append( ":" )
--- End diff --

Pls concatenate as follows `mavenProject.getGroupId() + ":" + 
mavenProject.getArtifactId()`.
This is simple and `javac` would compile to StringBuilder anyway, but 
longer in sources.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org



[GitHub] maven-surefire pull request #157: SUREFIRE-1383 dependenciesToScan Does Not ...

2017-06-29 Thread owenfarrell
GitHub user owenfarrell opened a pull request:

https://github.com/apache/maven-surefire/pull/157

SUREFIRE-1383 dependenciesToScan Does Not Leverage Classpath Elements

Added logic to prefer output directories of projects built as part of the 
current session.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/owenfarrell/maven-surefire master

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/maven-surefire/pull/157.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #157


commit 12bda800118b25397adbe15a3b21547aa1df2aeb
Author: Owen Farrell 
Date:   2017-06-29T21:12:34Z

SUREFIRE-1383: Added logic to use build output directories for session 
projects in favor of installed artifacts

commit 524bb05d2aad37ef90458408607085456e1f774a
Author: Owen Farrell 
Date:   2017-06-29T21:14:38Z

SUREFIRE-1383: Added logic to use build output directories for session 
projects in favor of installed artifacts




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

-
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org