Skip to content

Commit

Permalink
build: Dependencies updates [2020-11-02] (#1288)
Browse files Browse the repository at this point in the history
* [Automatic PR] Dependencies update

* Fix MultiLinePrinterTest

* Fix unit test

* Fix output logic

Co-authored-by: pawelpasterz <[email protected]>
Co-authored-by: Janek Góral <[email protected]>
Co-authored-by: Pawel Pasterz <[email protected]>
  • Loading branch information
4 people authored Nov 2, 2020
1 parent 22da7bf commit 208425c
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 14 deletions.
8 changes: 4 additions & 4 deletions buildSrc/src/main/kotlin/Versions.kt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ object Versions {
const val KOTLIN = "1.4.10"

// https://github.com/Kotlin/kotlinx.coroutines/releases
const val KOTLIN_COROUTINES = "1.3.9"
const val KOTLIN_COROUTINES = "1.4.0"

// https://github.com/remkop/picocli/releases
const val PICOCLI = "4.5.2"
Expand All @@ -38,7 +38,7 @@ object Versions {
const val GOOGLE_NIO = "0.121.2"

// https://search.maven.org/search?q=a:google-cloud-storage%20g:com.google.cloud
const val GOOGLE_STORAGE = "1.113.1"
const val GOOGLE_STORAGE = "1.113.2"

// https://github.com/google/gson/releases
const val GSON = "2.8.6"
Expand Down Expand Up @@ -79,7 +79,7 @@ object Versions {
const val COMMON_TEXT = "1.9"

// https://github.com/fusesource/jansi/releases
const val JANSI = "1.18"
const val JANSI = "2.0.1"

// https://github.com/ben-manes/gradle-versions-plugin/releases
const val BEN_MANES = "0.33.0"
Expand All @@ -88,9 +88,9 @@ object Versions {
const val PROGUARD = "7.0.0"

// ============== flank-scripts ==============
const val KOTLIN_SERIALIZATION = "1.0.1"
const val ARCHIVE_LIB = "1.1.0"
const val TUKAANI_XZ = "1.0"
const val KOTLIN_SERIALIZATION = "1.0.0"
const val FUEL = "2.3.0"
const val CLIKT = "2.8.0"
const val JCABI_GITHUB = "1.1.2"
Expand Down
2 changes: 1 addition & 1 deletion test_runner/src/main/kotlin/ftl/args/CreateCommonArgs.kt
Original file line number Diff line number Diff line change
Expand Up @@ -66,4 +66,4 @@ private val CommonConfig.defaultOutputStyle

private val CommonConfig.hasMultipleExecutions
get() = gcloud.flakyTestAttempts!! > 0 ||
(!flank.disableSharding!! && flank.maxTestShards!! > 0)
(!flank.disableSharding!! && flank.maxTestShards!! > 1)
10 changes: 5 additions & 5 deletions test_runner/src/test/kotlin/ftl/args/AndroidArgsTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ AndroidArgs
run-timeout: -1
legacy-junit-result: true
ignore-failed-tests: false
output-style: multi
output-style: verbose
disable-results-upload: false
default-class-test-time: 240.0
""".trimIndent(),
Expand Down Expand Up @@ -488,7 +488,7 @@ AndroidArgs
assert(testTargetsAlwaysRun, empty)
assert(disableSharding, false)
assert(runTimeout, "-1")
assert(outputStyle, OutputStyle.Multi)
assert(outputStyle, OutputStyle.Verbose)
assert(fullJUnitResult, false)
}
}
Expand Down Expand Up @@ -1199,17 +1199,17 @@ AndroidArgs
@Test
fun `cli output-style`() {
val cli = AndroidRunCommand()
CommandLine(cli).parseArgs("--output-style=verbose")
CommandLine(cli).parseArgs("--output-style=multi")

val yaml = """
gcloud:
app: $appApk
test: $testApk
"""
assertThat(AndroidArgs.load(yaml).validate().outputStyle).isEqualTo(OutputStyle.Multi)
assertThat(AndroidArgs.load(yaml).validate().outputStyle).isEqualTo(OutputStyle.Verbose)

val args = AndroidArgs.load(yaml, cli).validate()
assertThat(args.outputStyle).isEqualTo(OutputStyle.Verbose)
assertThat(args.outputStyle).isEqualTo(OutputStyle.Multi)
}

@Test(expected = FlankConfigurationError::class)
Expand Down
8 changes: 4 additions & 4 deletions test_runner/src/test/kotlin/ftl/args/IosArgsTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ IosArgs
local-result-dir: results
run-timeout: -1
ignore-failed-tests: false
output-style: multi
output-style: verbose
disable-results-upload: false
default-class-test-time: 240.0
""".trimIndent(),
Expand Down Expand Up @@ -858,17 +858,17 @@ IosArgs
@Test
fun `cli output-style`() {
val cli = IosRunCommand()
CommandLine(cli).parseArgs("--output-style=verbose")
CommandLine(cli).parseArgs("--output-style=multi")

val yaml = """
gcloud:
test: $testPath
xctestrun-file: $testPath
"""
assertThat(IosArgs.load(yaml).outputStyle).isEqualTo(OutputStyle.Multi)
assertThat(IosArgs.load(yaml).outputStyle).isEqualTo(OutputStyle.Verbose)

val args = IosArgs.load(yaml, cli)
assertThat(args.outputStyle).isEqualTo(OutputStyle.Verbose)
assertThat(args.outputStyle).isEqualTo(OutputStyle.Multi)
}

private fun getValidTestsSample() = listOf(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import io.mockk.every
import io.mockk.spyk
import io.mockk.verify
import org.fusesource.jansi.Ansi
import org.fusesource.jansi.AnsiConsole
import org.junit.Assert.assertEquals
import org.junit.Rule
import org.junit.Test
Expand All @@ -21,6 +22,7 @@ class MultiLinePrinterTest {
// given
val ansi = spyk(Ansi.ansi()) { every { this@spyk.toString() } returns "" }
val printChanges = MultiLinePrinter { ansi }
AnsiConsole.systemUninstall()

// when
printChanges(changes1)
Expand Down

0 comments on commit 208425c

Please sign in to comment.