1
0
mirror of https://github.com/lana-k/sqliteviz.git synced 2025-12-07 18:48:55 +08:00

storedQueries module is covered by tests

This commit is contained in:
lana-k
2021-01-27 21:00:22 +01:00
parent f640727d96
commit d45212733d
5 changed files with 118 additions and 13 deletions

View File

@@ -376,7 +376,7 @@ describe('mutations', () => {
})
describe('actions', () => {
it('addTab (new)', async () => {
it('addTab adds new blank tab', async () => {
// mock state
const state = {
tabs: [],
@@ -391,7 +391,7 @@ describe('actions', () => {
expect(state.untitledLastIndex).to.equal(1)
})
it('addTab (saved)', async () => {
it('addTab adds tab from saved queries', async () => {
// mock state
const state = {
tabs: [],
@@ -410,7 +410,7 @@ describe('actions', () => {
expect(state.untitledLastIndex).to.equal(0)
})
it('addTab (existed)', async () => {
it("addTab doesn't add anything when the query is already opened", async () => {
const tab1 = {
id: 1,
name: 'test',