From 4f71d4ff0d1e7ff4607b58eb7d030bd860e44f3a Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Sat, 4 Apr 2020 03:02:28 +0000 Subject: CTAN sync 202004040302 --- .../org/islandoftex/arara/model/SessionTest.kt | 76 ---------------------- 1 file changed, 76 deletions(-) delete mode 100644 support/arara/source/src/test/kotlin/org/islandoftex/arara/model/SessionTest.kt (limited to 'support/arara/source/src/test/kotlin/org/islandoftex/arara/model/SessionTest.kt') diff --git a/support/arara/source/src/test/kotlin/org/islandoftex/arara/model/SessionTest.kt b/support/arara/source/src/test/kotlin/org/islandoftex/arara/model/SessionTest.kt deleted file mode 100644 index 7580d8c81e..0000000000 --- a/support/arara/source/src/test/kotlin/org/islandoftex/arara/model/SessionTest.kt +++ /dev/null @@ -1,76 +0,0 @@ -// SPDX-License-Identifier: BSD-3-Clause -package org.islandoftex.arara.model - -import io.kotlintest.shouldBe -import io.kotlintest.shouldNotThrow -import io.kotlintest.shouldThrow -import io.kotlintest.specs.ShouldSpec - -class SessionTest : ShouldSpec({ - should("include all environment variables") { - Session.clear() - Session.updateEnvironmentVariables() - Session.contains("environment:PATH") shouldBe true - } - - should("properly check existence") { - Session.clear() - Session.put("A", "B") - Session.contains("A") shouldBe true - Session.contains("C") shouldBe false - } - - should("support insertion") { - Session.clear() - Session.put("A", "B") - Session.contains("A") shouldBe true - } - - should("support get") { - Session.clear() - Session.put("A", "B") - Session["A"] shouldBe "B" - } - - should("support removal") { - Session.clear() - Session.put("A", "B") - Session.put("C", "D") - Session.contains("A") shouldBe true - Session.contains("C") shouldBe true - Session.remove("A") - Session.contains("A") shouldBe false - Session.contains("C") shouldBe true - } - - should("clear itself") { - Session.clear() - Session.put("A", "B") - Session.put("C", "D") - Session.contains("A") shouldBe true - Session.contains("C") shouldBe true - Session.clear() - Session.contains("A") shouldBe false - Session.contains("C") shouldBe false - } - - should("throw on unknown removal") { - Session.clear() - Session.put("A", "B") - shouldNotThrow { - Session.remove("A") - } - shouldThrow { - Session.remove("C") - } - } - - should("throw on unknown getter") { - Session.clear() - Session.put("A", "B") - Session["A"] shouldBe "B" - shouldThrow { - Session["C"] - } - } -}) -- cgit v1.2.3