-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(goodstore): update tests and exports
- Loading branch information
1 parent
8e7a9df
commit 08640ad
Showing
250 changed files
with
4,734 additions
and
1,760 deletions.
There are no files selected for viewing
4 changes: 3 additions & 1 deletion
4
models/inventory-entry/src/inventory-entry-draft/presets/index.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,9 @@ | ||
import empty from "./empty"; | ||
import empty from './empty'; | ||
import sampleDataGoodStore from './sample-data-goodstore'; | ||
|
||
const presets = { | ||
empty, | ||
sampleDataGoodStore, | ||
}; | ||
|
||
export default presets; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 34 additions & 12 deletions
46
...inventory-entry/src/inventory-entry-draft/presets/sample-data-goodstore/sku-AAR34.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,39 @@ | ||
|
||
import { TInventoryEntryDraft, TInventoryEntryDraftGraphql } from '../../../types'; | ||
import { | ||
TInventoryEntryDraft, | ||
TInventoryEntryDraftGraphql, | ||
} from '../../../types'; | ||
import skuAAR34 from './sku-AAR34'; | ||
|
||
describe('With skuAAR34 preset', () => { | ||
it('should return skuAAR34 preset', () => { | ||
const skuAAR34Preset = skuAAR34().build<TInventoryEntryDraft>(); | ||
expect(skuAAR34Preset).toMatchInlineSnapshot(``); | ||
}); | ||
it('should return skuAAR34 preset', () => { | ||
const skuAAR34Preset = skuAAR34().build<TInventoryEntryDraft>(); | ||
expect(skuAAR34Preset).toMatchInlineSnapshot(` | ||
{ | ||
"custom": null, | ||
"expectedDelivery": undefined, | ||
"key": undefined, | ||
"quantityOnStock": 100, | ||
"restockableInDays": undefined, | ||
"sku": "AAR-34", | ||
"supplyChannel": undefined, | ||
} | ||
`); | ||
}); | ||
|
||
it('should return skuAAR34 preset when built for GraphQL', () => { | ||
const skuAAR34PresetGraphql = skuAAR34().buildGraphql<TInventoryEntryDraftGraphql>(); | ||
expect(skuAAR34PresetGraphql).toMatchInlineSnapshot(``); | ||
}); | ||
it('should return skuAAR34 preset when built for GraphQL', () => { | ||
const skuAAR34PresetGraphql = | ||
skuAAR34().buildGraphql<TInventoryEntryDraftGraphql>(); | ||
expect(skuAAR34PresetGraphql).toMatchInlineSnapshot(` | ||
{ | ||
"__typename": "InventoryEntryDraft", | ||
"custom": null, | ||
"expectedDelivery": undefined, | ||
"key": undefined, | ||
"quantityOnStock": 100, | ||
"restockableInDays": undefined, | ||
"sku": "AAR-34", | ||
"supplyChannel": undefined, | ||
} | ||
`); | ||
}); | ||
}); | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 34 additions & 12 deletions
46
...ventory-entry/src/inventory-entry-draft/presets/sample-data-goodstore/sku-ADARM04.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,39 @@ | ||
|
||
import { TInventoryEntryDraft, TInventoryEntryDraftGraphql } from '../../../types'; | ||
import { | ||
TInventoryEntryDraft, | ||
TInventoryEntryDraftGraphql, | ||
} from '../../../types'; | ||
import skuADARM04 from './sku-ADARM04'; | ||
|
||
describe('With skuADARM04 preset', () => { | ||
it('should return skuADARM04 preset', () => { | ||
const skuADARM04Preset = skuADARM04().build<TInventoryEntryDraft>(); | ||
expect(skuADARM04Preset).toMatchInlineSnapshot(``); | ||
}); | ||
it('should return skuADARM04 preset', () => { | ||
const skuADARM04Preset = skuADARM04().build<TInventoryEntryDraft>(); | ||
expect(skuADARM04Preset).toMatchInlineSnapshot(` | ||
{ | ||
"custom": null, | ||
"expectedDelivery": undefined, | ||
"key": undefined, | ||
"quantityOnStock": 100, | ||
"restockableInDays": undefined, | ||
"sku": "ADARM-04", | ||
"supplyChannel": undefined, | ||
} | ||
`); | ||
}); | ||
|
||
it('should return skuADARM04 preset when built for GraphQL', () => { | ||
const skuADARM04PresetGraphql = skuADARM04().buildGraphql<TInventoryEntryDraftGraphql>(); | ||
expect(skuADARM04PresetGraphql).toMatchInlineSnapshot(``); | ||
}); | ||
it('should return skuADARM04 preset when built for GraphQL', () => { | ||
const skuADARM04PresetGraphql = | ||
skuADARM04().buildGraphql<TInventoryEntryDraftGraphql>(); | ||
expect(skuADARM04PresetGraphql).toMatchInlineSnapshot(` | ||
{ | ||
"__typename": "InventoryEntryDraft", | ||
"custom": null, | ||
"expectedDelivery": undefined, | ||
"key": undefined, | ||
"quantityOnStock": 100, | ||
"restockableInDays": undefined, | ||
"sku": "ADARM-04", | ||
"supplyChannel": undefined, | ||
} | ||
`); | ||
}); | ||
}); | ||
|
||
|
Oops, something went wrong.