Skip to content

Commit

Permalink
Fix test for external
Browse files Browse the repository at this point in the history
  • Loading branch information
adrinr committed Sep 2, 2024
1 parent 2365a6e commit ae0e3cd
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions packages/server/src/api/routes/tests/viewV2.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1199,18 +1199,25 @@ describe.each([

const table = await config.api.table.save(
saveTableRequest({
schema: {},
})
)
await config.api.table.save({
...table,
schema: {
...table.schema,
aux: {
name: "aux",
relationshipType: RelationshipType.ONE_TO_MANY,
type: FieldType.LINK,
tableId: auxTable._id!,
fieldName: "fk_aux",
constraints: { presence: true },
constraints: { type: "array" },
},
},
})
)
// Refetch auxTable
auxTable = await config.api.table.get(auxTable._id!)

const view = await config.api.viewV2.create({
name: "view a",
Expand All @@ -1226,8 +1233,6 @@ describe.each([
},
})

// Refetch autTable
auxTable = await config.api.table.get(auxTable._id!)
await config.api.table.save({
...auxTable,
schema: {
Expand Down

0 comments on commit ae0e3cd

Please sign in to comment.