@@ -23,7 +23,7 @@ class CustomCollectionTests: AppTestCase {
2323
2424 func test_CustomCollection_save( ) async throws {
2525 // MUT
26- try await CustomCollection ( id: . id0, name: " List " , url: " https://github.com/foo/bar/list.json " )
26+ try await CustomCollection ( id: . id0, . init ( name: " List " , url: " https://github.com/foo/bar/list.json " ) )
2727 . save ( on: app. db)
2828
2929 do { // validate
@@ -33,7 +33,7 @@ class CustomCollectionTests: AppTestCase {
3333 }
3434
3535 do { // ensure name is unique
36- try await CustomCollection ( name: " List " , url: " https://github.com/foo/bar/other-list.json " )
36+ try await CustomCollection ( . init ( name: " List " , url: " https://github.com/foo/bar/other-list.json " ) )
3737 . save ( on: app. db)
3838 XCTFail ( " Expected failure " )
3939 } catch {
@@ -43,7 +43,7 @@ class CustomCollectionTests: AppTestCase {
4343 }
4444
4545 do { // ensure url is unique
46- try await CustomCollection ( name: " List 2 " , url: " https://github.com/foo/bar/list.json " )
46+ try await CustomCollection ( . init ( name: " List 2 " , url: " https://github.com/foo/bar/list.json " ) )
4747 . save ( on: app. db)
4848 XCTFail ( " Expected failure " )
4949 } catch {
@@ -87,7 +87,7 @@ class CustomCollectionTests: AppTestCase {
8787 // setup
8888 let pkg = Package ( id: . id0, url: " 1 " . asGithubUrl. url)
8989 try await pkg. save ( on: app. db)
90- let collection = CustomCollection ( id: . id1, name: " List " , url: " https://github.com/foo/bar/list.json " )
90+ let collection = CustomCollection ( id: . id1, . init ( name: " List " , url: " https://github.com/foo/bar/list.json " ) )
9191 try await collection. save ( on: app. db)
9292
9393 // MUT
@@ -118,7 +118,7 @@ class CustomCollectionTests: AppTestCase {
118118 // setup
119119 let pkg = Package ( id: . id0, url: " 1 " . asGithubUrl. url)
120120 try await pkg. save ( on: app. db)
121- let collection = CustomCollection ( id: . id1, name: " List " , url: " https://github.com/foo/bar/list.json " )
121+ let collection = CustomCollection ( id: . id1, . init ( name: " List " , url: " https://github.com/foo/bar/list.json " ) )
122122 try await collection. save ( on: app. db)
123123 try await collection. $packages. attach ( pkg, on: app. db)
124124
@@ -142,7 +142,7 @@ class CustomCollectionTests: AppTestCase {
142142 try await p1. save ( on: app. db)
143143 let p2 = Package ( id: . id1, url: " 2 " . asGithubUrl. url)
144144 try await p2. save ( on: app. db)
145- let collection = CustomCollection ( id: . id2, name: " List " , url: " https://github.com/foo/bar/list.json " )
145+ let collection = CustomCollection ( id: . id2, . init ( name: " List " , url: " https://github.com/foo/bar/list.json " ) )
146146 try await collection. save ( on: app. db)
147147 try await collection. $packages. attach ( [ p1, p2] , on: app. db)
148148
@@ -158,7 +158,7 @@ class CustomCollectionTests: AppTestCase {
158158 // setup
159159 let pkg = Package ( id: . id0, url: " 1 " . asGithubUrl. url)
160160 try await pkg. save ( on: app. db)
161- let collection = CustomCollection ( id: . id1, name: " List " , url: " https://github.com/foo/bar/list.json " )
161+ let collection = CustomCollection ( id: . id1, . init ( name: " List " , url: " https://github.com/foo/bar/list.json " ) )
162162 try await collection. save ( on: app. db)
163163 try await collection. $packages. attach ( pkg, on: app. db)
164164 do {
@@ -196,7 +196,7 @@ class CustomCollectionTests: AppTestCase {
196196 // setup
197197 let pkg = Package ( id: . id0, url: " 1 " . asGithubUrl. url)
198198 try await pkg. save ( on: app. db)
199- let collection = CustomCollection ( id: . id1, name: " List " , url: " https://github.com/foo/bar/list.json " )
199+ let collection = CustomCollection ( id: . id1, . init ( name: " List " , url: " https://github.com/foo/bar/list.json " ) )
200200 try await collection. save ( on: app. db)
201201 try await collection. $packages. attach ( pkg, on: app. db)
202202 do {
@@ -232,7 +232,7 @@ class CustomCollectionTests: AppTestCase {
232232
233233 func test_CustomCollection_reconcile( ) async throws {
234234 // Test reconciliation of a custom collection against a list of package URLs
235- let collection = CustomCollection ( id: . id0, name: " List " , url: " https://github.com/foo/bar/list.json " )
235+ let collection = CustomCollection ( id: . id0, . init ( name: " List " , url: " https://github.com/foo/bar/list.json " ) )
236236 try await collection. save ( on: app. db)
237237 try await Package ( id: . id1, url: URL ( " https://a " ) ) . save ( on: app. db)
238238 try await Package ( id: . id2, url: URL ( " https://b " ) ) . save ( on: app. db)
0 commit comments