Fix merge conflicts
This commit is contained in:
parent
516b5691e8
commit
49980dadf1
1 changed files with 7 additions and 18 deletions
|
@ -94,11 +94,7 @@ describe("/v2/views", () => {
|
||||||
|
|
||||||
it("returns views with query info", async () => {
|
it("returns views with query info", async () => {
|
||||||
const newView = await config.api.viewV2.create({ ...viewFilters })
|
const newView = await config.api.viewV2.create({ ...viewFilters })
|
||||||
const res = await request
|
const res = await config.api.viewV2.fetch(config.table!._id)
|
||||||
.get(`/api/v2/views?tableId=${config.table!._id}`)
|
|
||||||
.set(config.defaultHeaders())
|
|
||||||
.expect("Content-Type", /json/)
|
|
||||||
.expect(200)
|
|
||||||
|
|
||||||
expect(res.body.views.length).toBe(11)
|
expect(res.body.views.length).toBe(11)
|
||||||
expect(newView.query).toEqual({ allOr: false, equal: { field: "value" } })
|
expect(newView.query).toEqual({ allOr: false, equal: { field: "value" } })
|
||||||
|
@ -164,20 +160,13 @@ describe("/v2/views", () => {
|
||||||
tableId: config.table!._id!,
|
tableId: config.table!._id!,
|
||||||
...viewFilters,
|
...viewFilters,
|
||||||
}
|
}
|
||||||
const res = await request
|
const res = await config.api.viewV2.create(newView)
|
||||||
.post(`/api/v2/views`)
|
|
||||||
.send(newView)
|
|
||||||
.set(config.defaultHeaders())
|
|
||||||
.expect("Content-Type", /json/)
|
|
||||||
.expect(201)
|
|
||||||
|
|
||||||
expect(res.body).toEqual({
|
expect(res).toEqual({
|
||||||
data: {
|
...newView,
|
||||||
...newView,
|
...viewFilters,
|
||||||
...viewFilters,
|
_id: expect.any(String),
|
||||||
_id: expect.any(String),
|
_rev: expect.any(String),
|
||||||
_rev: expect.any(String),
|
|
||||||
},
|
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue