Skip to content

Commit

Permalink
update extension-store-canner test
Browse files Browse the repository at this point in the history
  • Loading branch information
fredalai committed Aug 11, 2023
1 parent 7dab72d commit 79ec99b
Showing 1 changed file with 18 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@ import * as sinon from 'ts-sinon';
import faker from '@faker-js/faker';
import * as oas3 from 'openapi3-ts';
import { BaseStorageService } from '@canner/canner-storage';
import { APISchema, ArtifactBuilderOptions } from '@vulcan-sql/core';
import {
APISchema,
ArtifactBuilderOptions,
CacheLayerInfo,
} from '@vulcan-sql/core';
import * as storageServiceModule from '../lib/storageService';
import {
BuiltInArtifact,
Expand Down Expand Up @@ -160,6 +164,12 @@ describe('Test CannerPersistenceStore', () => {
urlPath: '/orders',
templateSource: 'sales/orders',
profiles: [faker.word.noun()],
cache: [
{
...sinon.stubInterface<CacheLayerInfo>(),
profile: faker.lorem.word(),
},
],
},
],
specs: {
Expand All @@ -184,6 +194,7 @@ describe('Test CannerPersistenceStore', () => {
urlPath: '/products/:id',
templateSource: 'marketing/products',
profiles: [faker.word.noun()],
cache: [],
},
],
specs: {
Expand Down Expand Up @@ -213,11 +224,17 @@ describe('Test CannerPersistenceStore', () => {
urlPath: `${fakeWorkspaces.ws1.sqlName}/orders`,
templateSource: `${fakeWorkspaces.ws1.sqlName}/sales/orders`,
profiles: [`canner-${fakeWorkspaces.ws1.sqlName}`],
cache: [
{
profile: `canner-${fakeWorkspaces.ws1.sqlName}`,
},
],
},
{
urlPath: `${fakeWorkspaces.ws2.sqlName}/products/:id`,
templateSource: `${fakeWorkspaces.ws2.sqlName}/marketing/products`,
profiles: [`canner-${fakeWorkspaces.ws2.sqlName}`],
cache: [],
},
],
specs: {
Expand Down

0 comments on commit 79ec99b

Please sign in to comment.