|
12 | 12 | // See the License for the specific language governing permissions and
|
13 | 13 | // limitations under the License.
|
14 | 14 |
|
15 |
| -import XCTest |
16 |
| - |
17 | 15 | @testable import S3Store
|
18 | 16 |
|
| 17 | +import Testing |
| 18 | + |
19 | 19 |
|
20 |
| -final class S3StoreTests: XCTestCase { |
| 20 | +@Suite struct S3StoreTests { |
21 | 21 |
|
22 |
| - func test_Key_path() throws { |
| 22 | + @Test func Key_path() throws { |
23 | 23 | do {
|
24 | 24 | let key = S3Store.Key(bucket: "bucket", path: "foo/bar")
|
25 |
| - XCTAssertEqual(key.path, "foo/bar") |
| 25 | + #expect(key.path == "foo/bar") |
26 | 26 | }
|
27 | 27 | do {
|
28 | 28 | let key = S3Store.Key(bucket: "bucket", path: "/foo/bar")
|
29 |
| - XCTAssertEqual(key.path, "foo/bar") |
| 29 | + #expect(key.path == "foo/bar") |
30 | 30 | }
|
31 | 31 | do {
|
32 | 32 | let key = S3Store.Key(bucket: "bucket", path: "//foo/bar")
|
33 |
| - XCTAssertEqual(key.path, "foo/bar") |
| 33 | + #expect(key.path == "foo/bar") |
34 | 34 | }
|
35 | 35 | }
|
36 | 36 |
|
37 |
| - func test_Key_objectUrl() throws { |
| 37 | + @Test func Key_objectUrl() throws { |
38 | 38 | let key = S3Store.Key(bucket: "bucket", path: "foo/bar")
|
39 |
| - XCTAssertEqual(key.objectUrl, "https://bucket.s3.us-east-2.amazonaws.com/foo/bar") |
| 39 | + #expect(key.objectUrl == "https://bucket.s3.us-east-2.amazonaws.com/foo/bar") |
40 | 40 | }
|
41 | 41 |
|
42 |
| - func test_Key_s3Uri() throws { |
| 42 | + @Test func Key_s3Uri() throws { |
43 | 43 | let key = S3Store.Key(bucket: "bucket", path: "foo/bar")
|
44 |
| - XCTAssertEqual(key.s3Uri, "s3://bucket/foo/bar") |
| 44 | + #expect(key.s3Uri == "s3://bucket/foo/bar") |
45 | 45 | }
|
46 | 46 |
|
47 | 47 | }
|
0 commit comments