File tree Expand file tree Collapse file tree
Tests/CoreModelMongoDBTests Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -198,7 +198,7 @@ internal extension MongoDatabase {
198198 }
199199}
200200
201- fileprivate extension MongoDatabase {
201+ private extension MongoDatabase {
202202
203203 func collection(
204204 _ name: EntityName ,
Original file line number Diff line number Diff line change @@ -30,16 +30,17 @@ final class MongoDBModelTests: XCTestCase {
3030 name: " John Appleseed " ,
3131 age: 22
3232 )
33-
34- try await store. insert ( person1)
35-
33+
3634 var event1 = Event (
3735 name: " WWDC " ,
38- date: Date ( timeIntervalSinceNow: 60 * 60 * 24 * 10 ) ,
39- people: [ person1. id]
36+ date: Date ( timeIntervalSinceNow: 60 * 60 * 24 * 10 )
4037 )
4138
39+ event1. people. append ( person1. id)
40+ person1. events. append ( event1. id)
41+
4242 try await store. insert ( event1)
43+ try await store. insert ( person1)
4344 person1 = try await store. fetch ( Person . self, for: person1. id) !
4445 XCTAssertEqual ( person1. events, [ event1. id] )
4546 event1 = try await store. fetch ( Event . self, for: event1. id) !
You can’t perform that action at this time.
0 commit comments