From f9f0b93d4e5ed1386c756dc09814b2b4d28bfbf8 Mon Sep 17 00:00:00 2001 From: Yair Morgenstern Date: Thu, 3 Sep 2020 17:33:56 +0300 Subject: [PATCH] "Make travis output test output" take 2 --- .travis.yml | 2 +- core/src/com/unciv/models/ruleset/Ruleset.kt | 8 +++++--- tests/build.gradle.kts | 5 +---- tests/src/com/unciv/testing/BasicTests.kt | 2 -- 4 files changed, 7 insertions(+), 10 deletions(-) diff --git a/.travis.yml b/.travis.yml index a690f9f2..e81fdb9a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,4 @@ -language: android + language: android dist: trusty # For oracleJDK fail errors, as per advice from https://travis-ci.community/t/error-installing-oraclejdk8-expected-feature-release-number-in-range-of-9-to-14-but-got-8/3766/6 diff --git a/core/src/com/unciv/models/ruleset/Ruleset.kt b/core/src/com/unciv/models/ruleset/Ruleset.kt index c1b8d1b0..30509e15 100644 --- a/core/src/com/unciv/models/ruleset/Ruleset.kt +++ b/core/src/com/unciv/models/ruleset/Ruleset.kt @@ -226,9 +226,11 @@ object RulesetCache :HashMap() { if(printOutput) println("Mod loaded successfully: " + modRuleset.name) if(printOutput) checkModLinks(modRuleset) } catch (ex: Exception) { - println("Exception loading mod '${modFolder.name()}':") - println(" ${ex.localizedMessage}") - println(" (Source file ${ex.stackTrace[0].fileName} line ${ex.stackTrace[0].lineNumber})") + if (printOutput) { + println("Exception loading mod '${modFolder.name()}':") + println(" ${ex.localizedMessage}") + println(" (Source file ${ex.stackTrace[0].fileName} line ${ex.stackTrace[0].lineNumber})") + } } } } diff --git a/tests/build.gradle.kts b/tests/build.gradle.kts index 2455deaf..cb93b530 100644 --- a/tests/build.gradle.kts +++ b/tests/build.gradle.kts @@ -12,12 +12,9 @@ java { tasks { test { workingDir = file("../android/assets") - testLogging.debug { + testLogging.lifecycle { events( - TestLogEvent.STARTED, TestLogEvent.FAILED, - TestLogEvent.PASSED, - TestLogEvent.SKIPPED, TestLogEvent.STANDARD_ERROR, TestLogEvent.STANDARD_OUT ) diff --git a/tests/src/com/unciv/testing/BasicTests.kt b/tests/src/com/unciv/testing/BasicTests.kt index 780a1ef8..1d05e346 100644 --- a/tests/src/com/unciv/testing/BasicTests.kt +++ b/tests/src/com/unciv/testing/BasicTests.kt @@ -76,8 +76,6 @@ class BasicTests { UncivGame.Current = UncivGame("") UncivGame.Current.settings = GameSettings().apply { language = "Italian" } - val x = "+1 Gold, +2 Production".tr() - print(x) } // @Test // This should NOT run as part of the test suite!