James Kuszmaul | 397f6fe | 2020-01-04 16:21:52 -0800 | [diff] [blame^] | 1 | model {
|
| 2 | tasks {
|
| 3 | def ts = $.testSuites
|
| 4 | project.tasks.register('testDesktopCpp') { testTask->
|
| 5 | def systemArch = getCurrentArch()
|
| 6 | def found = false
|
| 7 | ts.each {
|
| 8 | if (it in GoogleTestTestSuiteSpec && it.name == "${nativeName}Test") {
|
| 9 | it.binaries.each {
|
| 10 | if (found) return
|
| 11 | def arch = it.targetPlatform.name
|
| 12 | if (arch == systemArch && it.buildType.name == 'debug') {
|
| 13 | testTask.dependsOn it.tasks.run
|
| 14 | found = true
|
| 15 | }
|
| 16 | }
|
| 17 | }
|
| 18 | }
|
| 19 | }
|
| 20 | }
|
| 21 | }
|