Skip to content

Commit 7b3ac14

Browse files
committed
Normalize constant names for tag properties in KotestEngineProperties.
1 parent 627b5f8 commit 7b3ac14

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed

kotest-framework/kotest-framework-engine/src/commonMain/kotlin/io/kotest/engine/config/KotestEngineProperties.kt

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,17 @@ object KotestEngineProperties {
99
*/
1010
internal const val TAG_EXPRESSION = "kotest.tags"
1111

12-
internal const val excludeTags = "kotest.tags.exclude"
12+
/**
13+
* A comma separated list of tags to exclude.
14+
* For a more powerful way of including and excluding tags see [TAG_EXPRESSION].
15+
*/
16+
internal const val EXCLUDE_TAGS = "kotest.tags.exclude"
1317

14-
internal const val includeTags = "kotest.tags.include"
18+
/**
19+
* A comma separated list of tags to include.
20+
* For a more powerful way of including and excluding tags see [TAG_EXPRESSION].
21+
*/
22+
internal const val INCLUDE_TAGS = "kotest.tags.include"
1523

1624
/**
1725
* A regex expression that is used to match the test [io.kotest.core.descriptors.Descriptor]'s path

kotest-framework/kotest-framework-engine/src/commonMain/kotlin/io/kotest/engine/extensions/SystemPropertyTagExtension.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ import io.kotest.common.syspropOrEnv
99

1010
/**
1111
* This [TagExtension] includes and excludes tags using the system properties:
12-
* [KotestEngineProperties.TAG_EXPRESSION], [KotestEngineProperties.includeTags]
13-
* and [KotestEngineProperties.excludeTags].
12+
* [KotestEngineProperties.TAG_EXPRESSION], [KotestEngineProperties.INCLUDE_TAGS]
13+
* and [KotestEngineProperties.EXCLUDE_TAGS].
1414
*
1515
* Note: If [KotestEngineProperties.TAG_EXPRESSION] is used then the other two properties will be ignored.
1616
*
@@ -23,8 +23,8 @@ object SystemPropertyTagExtension : TagExtension {
2323
fun readTagsProperty(name: String): List<Tag> =
2424
(syspropOrEnv(name) ?: "").split(',').filter { it.isNotBlank() }.map { NamedTag(it.trim()) }
2525

26-
val includedTags = readTagsProperty(KotestEngineProperties.includeTags)
27-
val excludedTags = readTagsProperty(KotestEngineProperties.excludeTags)
26+
val includedTags = readTagsProperty(KotestEngineProperties.INCLUDE_TAGS)
27+
val excludedTags = readTagsProperty(KotestEngineProperties.EXCLUDE_TAGS)
2828
val expression = syspropOrEnv(KotestEngineProperties.TAG_EXPRESSION)
2929

3030
return if (expression == null)

0 commit comments

Comments
 (0)