Skip to content

Commit b5f04bf

Browse files
committed
Add test case for identity case insensitivity.
1 parent 20a6ee9 commit b5f04bf

File tree

4 files changed

+53
-0
lines changed

4 files changed

+53
-0
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"object": {
3+
"pins": [
4+
{
5+
"package": "Yams",
6+
"repositoryURL": "https://github.com/jpsim/Yams.git",
7+
"state": {
8+
"branch": null,
9+
"revision": "01835dc202670b5bb90d07f3eae41867e9ed29f6",
10+
"version": "5.0.1"
11+
}
12+
}
13+
]
14+
},
15+
"version": 1
16+
}
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
// swift-tools-version:5.4
2+
// The swift-tools-version declares the minimum version of Swift required to build this package.
3+
4+
import PackageDescription
5+
6+
let package = Package(
7+
name: "identity-case",
8+
products: [
9+
// Products define the executables and libraries a package produces, and make them visible to other packages.
10+
.library(
11+
name: "identity-case",
12+
targets: ["identity-case"]),
13+
],
14+
dependencies: [
15+
// Dependencies declare other packages that this package depends on.
16+
.package(url: "https://github.com/jpsim/Yams.git", from: "5.0.0"),
17+
],
18+
targets: [
19+
// Targets are the basic building blocks of a package. A target can define a module or a test suite.
20+
// Targets can depend on other targets in this package, and on products in packages this package depends on.
21+
.target(
22+
name: "identity-case",
23+
dependencies: ["Yams"]),
24+
]
25+
)
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
public struct identity_case {
2+
public private(set) var text = "Hello, World!"
3+
4+
public init() {
5+
}
6+
}

test/suite/SwiftPackage.test.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,4 +63,10 @@ suite("SwiftPackage Test Suite", () => {
6363
assert.strictEqual(spmPackage.isValid, true);
6464
assert(spmPackage.resolved !== undefined);
6565
}).timeout(15000);
66+
67+
test("Identity case-insensitivity", async () => {
68+
const spmPackage = await SwiftPackage.create(testAssetUri("identity-case"));
69+
assert.strictEqual(spmPackage.isValid, true);
70+
assert(spmPackage.resolved !== undefined);
71+
}).timeout(10000);
6672
});

0 commit comments

Comments
 (0)