()
| 2 | |
| 3 | describe("clientdb query", () => { |
| 4 | function getTestDb() { |
| 5 | const db = createTestDb(); |
| 6 | |
| 7 | const adam = db.entity(owner).create({ name: "Adam" }); |
| 8 | const omar = db.entity(owner).create({ name: "Omar" }); |
| 9 | |
| 10 | const adams_rex = db.entity(dog).create({ name: "rex", owner_id: adam.id }); |
| 11 | const adams_teddy = db |
| 12 | .entity(dog) |
| 13 | .create({ name: "teddy", owner_id: adam.id }); |
| 14 | |
| 15 | const omars_rudy = db |
| 16 | .entity(dog) |
| 17 | .create({ name: "rudy", owner_id: omar.id }); |
| 18 | const omars_rex = db.entity(dog).create({ name: "rex", owner_id: omar.id }); |
| 19 | |
| 20 | return [ |
| 21 | db, |
| 22 | { |
| 23 | owners: { adam, omar }, |
| 24 | dogs: { adams_rex, adams_teddy, omars_rudy, omars_rex }, |
| 25 | }, |
| 26 | ] as const; |
| 27 | } |
| 28 | |
| 29 | it("performs simple query", () => { |
| 30 | const [db, data] = getTestDb(); |
no test coverage detected