Skip to content

Commit 315300c

Browse files
author
Val
committed
Add tests for arm simulator targets
1 parent 9b8c919 commit 315300c

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

src/test/kotlin/com/chromaticnoise/multiplatformswiftpackage/dsl/TargetPlatformDslTest.kt

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ class TargetPlatformDslTest : StringSpec() {
2525
.shouldHaveTarget("iosX64")
2626
}
2727

28+
"adding ios targets should add arm 64 simulator target" {
29+
TargetPlatformDsl().apply { iOS(someVersion) }.targetPlatforms
30+
.shouldHaveTarget("iosSimulatorArm64")
31+
}
32+
2833
"adding watchOS targets should add arm 32 target" {
2934
TargetPlatformDsl().apply { watchOS(someVersion) }.targetPlatforms
3035
.shouldHaveTarget("watchosArm32")
@@ -40,6 +45,11 @@ class TargetPlatformDslTest : StringSpec() {
4045
.shouldHaveTarget("watchosX86")
4146
}
4247

48+
"adding watchOS targets should add arm 64 simulator target" {
49+
TargetPlatformDsl().apply { watchOS(someVersion) }.targetPlatforms
50+
.shouldHaveTarget("watchosSimulatorArm64")
51+
}
52+
4353
"adding tvOS targets should add arm 64 target" {
4454
TargetPlatformDsl().apply { tvOS(someVersion) }.targetPlatforms
4555
.shouldHaveTarget("tvosArm64")
@@ -50,11 +60,21 @@ class TargetPlatformDslTest : StringSpec() {
5060
.shouldHaveTarget("tvosX64")
5161
}
5262

63+
"adding tvOS targets should add arm 64 simulator target" {
64+
TargetPlatformDsl().apply { tvOS(someVersion) }.targetPlatforms
65+
.shouldHaveTarget("tvosSimulatorArm64")
66+
}
67+
5368
"adding macOS targets should add x64 target" {
5469
TargetPlatformDsl().apply { macOS(someVersion) }.targetPlatforms
5570
.shouldHaveTarget("macosX64")
5671
}
5772

73+
"adding macOS targets should add arm 64 target" {
74+
TargetPlatformDsl().apply { macOS(someVersion) }.targetPlatforms
75+
.shouldHaveTarget("macosArm64")
76+
}
77+
5878
"adding target without names should not add a platform target" {
5979
TargetPlatformDsl().apply { targets(version = someVersion) }.targetPlatforms
6080
.shouldBeEmpty()

0 commit comments

Comments
 (0)