Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
split the single gradle project to subprojects
+ extract `junit4` subproject + extract `testng` subproject + extract `grid` subproject
- Loading branch information
Showing
45 changed files
with
244 additions
and
232 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
org.gradle.parallel=true | ||
org.gradle.configureondemand=true | ||
org.gradle.jvmargs=-Xmx256m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 | ||
|
||
org.gradle.caching=true | ||
org.gradle.console=rich | ||
org.gradle.logging.level=lifecycle |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,13 @@ | ||
ext { | ||
encoding = 'UTF-8' | ||
} | ||
allprojects { | ||
ext { | ||
encoding = 'UTF-8' | ||
} | ||
|
||
tasks.withType(JavaCompile) { | ||
options.encoding = encoding | ||
options.debug = true | ||
} | ||
compileJava.options.debugOptions.debugLevel = "source,lines,vars" | ||
tasks.withType(JavaCompile) { | ||
options.encoding = encoding | ||
options.debug = true | ||
} | ||
compileJava.options.debugOptions.debugLevel = "source,lines,vars" | ||
|
||
sourceCompatibility = '1.8' | ||
sourceCompatibility = '1.8' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,107 +1,83 @@ | ||
test { | ||
include 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task ie(type: Test) { | ||
systemProperties['selenide.browser'] = 'ie' | ||
systemProperties['selenide.timeout'] = '8000' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/ie' | ||
include 'integration/**/*' | ||
exclude '**/AlertText.*' | ||
exclude '**/ConfirmTest.*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task edge(type: Test) { | ||
systemProperties['selenide.browser'] = 'edge' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/edge' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task chrome(type: Test) { | ||
systemProperties['selenide.browser'] = 'chrome' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/chrome' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task chrome_headless(type: Test) { | ||
systemProperties['selenide.browser'] = 'chrome' | ||
systemProperties['selenide.headless'] = 'true' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/chrome_headless' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task chrome_remote(type: Test) { | ||
systemProperties['selenide.remote'] = 'http://localhost:4444/wd/hub' | ||
systemProperties['selenide.browser'] = 'chrome' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/chrome_remote' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
allprojects { | ||
test { | ||
include 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task firefox(type: Test) { | ||
systemProperties['selenide.browser'] = 'firefox' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/firefox' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
task ie(type: Test) { | ||
systemProperties['selenide.browser'] = 'ie' | ||
systemProperties['selenide.timeout'] = '8000' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/ie' | ||
include 'integration/**/*' | ||
exclude '**/AlertText.*' | ||
exclude '**/ConfirmTest.*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task firefox_headless(type: Test) { | ||
systemProperties['selenide.browser'] = 'firefox' | ||
systemProperties['selenide.headless'] = 'true' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/firefox_headless' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
task edge(type: Test) { | ||
systemProperties['selenide.browser'] = 'edge' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/edge' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task firefox_remote(type: Test) { | ||
systemProperties['selenide.remote'] = 'http://localhost:4444/wd/hub' | ||
systemProperties['selenide.browser'] = 'firefox' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/firefox_remote' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
task chrome(type: Test) { | ||
systemProperties['selenide.browser'] = 'chrome' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/chrome' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task grid(type: Test) { | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/grid' | ||
include 'grid/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
task chrome_headless(type: Test) { | ||
systemProperties['selenide.browser'] = 'chrome' | ||
systemProperties['selenide.headless'] = 'true' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/chrome_headless' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
task testng(type: Test) { | ||
useTestNG() | ||
include '**/testng/**/*' | ||
systemProperties['selenide.browser'] = 'chrome' | ||
systemProperties['selenide.headless'] = 'true' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/testng' | ||
} | ||
task chrome_remote(type: Test) { | ||
systemProperties['selenide.remote'] = 'http://localhost:4444/wd/hub' | ||
systemProperties['selenide.browser'] = 'chrome' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/chrome_remote' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
tasks.withType(Test) { | ||
useJUnitPlatform() | ||
systemProperty('file.encoding', encoding) | ||
systemProperty('BUILD_URL', System.getenv()['BUILD_URL']) | ||
if (System.getenv('CI')) { | ||
maxParallelForks = 1 | ||
} else { | ||
maxParallelForks = (int) Runtime.runtime.availableProcessors().intdiv(2) ?: 1 | ||
task firefox(type: Test) { | ||
systemProperties['selenide.browser'] = 'firefox' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/firefox' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
jvmArgs = ['-ea', '-Xmx512m'] | ||
systemProperties += System.properties | ||
|
||
classpath += project.sourceSets.staticFacade.output.classesDirs | ||
classpath += project.sourceSets.staticFacadeTest.output.classesDirs | ||
testClassesDirs += project.sourceSets.staticFacadeTest.output.classesDirs | ||
task firefox_headless(type: Test) { | ||
systemProperties['selenide.browser'] = 'firefox' | ||
systemProperties['selenide.headless'] = 'true' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/firefox_headless' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
|
||
jacoco { | ||
enabled = true | ||
includes = ['com/codeborne/selenide/**/*'] | ||
task firefox_remote(type: Test) { | ||
systemProperties['selenide.remote'] = 'http://localhost:4444/wd/hub' | ||
systemProperties['selenide.browser'] = 'firefox' | ||
systemProperties['selenide.reportsFolder'] = 'build/reports/tests/firefox_remote' | ||
include 'integration/**/*' | ||
exclude 'com/codeborne/selenide/**/*' | ||
} | ||
outputs.upToDateWhen { | ||
false | ||
|
||
tasks.withType(Test) { | ||
useJUnitPlatform() | ||
systemProperty('file.encoding', encoding) | ||
systemProperty('BUILD_URL', System.getenv()['BUILD_URL']) | ||
if (System.getenv('CI')) { | ||
maxParallelForks = 1 | ||
} else { | ||
maxParallelForks = (int) Runtime.runtime.availableProcessors().intdiv(2) ?: 1 | ||
} | ||
jvmArgs = ['-ea', '-Xmx512m'] | ||
systemProperties += System.properties | ||
} | ||
} | ||
|
||
task allTests(dependsOn: ['clean', 'check', 'test', 'grid', 'firefox_headless', 'chrome_headless']) {} | ||
task allTests(dependsOn: ['clean', 'check', 'firefox_headless', 'chrome_headless']) {} |
Oops, something went wrong.