fix: make apiContext auto-fixture and fix remaining view ID conflicts
This commit is contained in:
parent
4888b1d8ca
commit
adcc74b056
|
|
@ -421,9 +421,9 @@ test.describe('Task', () => {
|
|||
|
||||
test('Can move a task to another project', async ({authenticatedPage: page}) => {
|
||||
const projects = await ProjectFactory.create(2)
|
||||
const views = await createDefaultViews(projects[0].id)
|
||||
const views = await createDefaultViews(projects[0].id, 10)
|
||||
// Also create views for the target project
|
||||
await createDefaultViews(projects[1].id, 5)
|
||||
await createDefaultViews(projects[1].id, 14)
|
||||
await BucketFactory.create(2, {
|
||||
project_view_id: views[3].id,
|
||||
})
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ export const test = base.extend<{
|
|||
currentUser: any;
|
||||
userToken: string;
|
||||
}>({
|
||||
apiContext: async ({playwright}, use) => {
|
||||
apiContext: [async ({playwright}, use) => {
|
||||
const baseURL = process.env.API_URL || 'http://localhost:3456/api/v1/'
|
||||
const apiContext = await playwright.request.newContext({
|
||||
baseURL,
|
||||
|
|
@ -18,7 +18,7 @@ export const test = base.extend<{
|
|||
await Factory.truncateAll()
|
||||
await use(apiContext)
|
||||
await apiContext.dispose()
|
||||
},
|
||||
}, {auto: true}],
|
||||
|
||||
currentUser: async ({apiContext}, use) => {
|
||||
const user = await createFakeUser()
|
||||
|
|
|
|||
Loading…
Reference in New Issue