We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0d05609 commit a1ab1e3Copy full SHA for a1ab1e3
tests/integration/tests/enhancements/with-policy/auth.test.ts
@@ -456,6 +456,15 @@ describe('auth() runtime test', () => {
456
await expect(
457
db.post.create({ data: { title: 'post3', author: { connect: { email: 'user2@abc.com' } } } })
458
).resolves.toMatchObject({ authorId: 'userId-2' });
459
+
460
+ // upsert
461
+ await expect(
462
+ db.post.upsert({
463
+ where: { id: 'post4' },
464
+ create: { id: 'post4', title: 'post4' },
465
+ update: { title: 'post4' },
466
+ })
467
+ ).resolves.toMatchObject({ authorId: 'userId-1' });
468
});
469
470
it('Default auth() with nested user context value', async () => {
0 commit comments