lint fixes and rename
This commit is contained in:
parent
69c21412f1
commit
4a924536f9
4 changed files with 18 additions and 12 deletions
|
@ -238,6 +238,10 @@ describe('Pattern', () => {
|
|||
}
|
||||
})
|
||||
|
||||
it(
|
||||
'Pattern.__init() should resolve nested dependencies for multiple parts that depend on the same part'
|
||||
)
|
||||
|
||||
// I am aware this does too much for one unit test, but this is to simplify TDD
|
||||
// we can split it up later
|
||||
it('Pattern.__init() should resolve nested injections', () => {
|
||||
|
|
|
@ -54,11 +54,14 @@ describe('Pattern', () => {
|
|||
name: 'test',
|
||||
draft: ({ part }) => part,
|
||||
}
|
||||
const design = new Design({ parts: [test] })
|
||||
const you = {
|
||||
name: 'you',
|
||||
draft: ({ part }) => part,
|
||||
}
|
||||
const design = new Design({ parts: [test, you] })
|
||||
const pattern = new design({ only: ['you'] })
|
||||
pattern.draft()
|
||||
expect(pattern.setStores[0].logs.debug.length).to.equal(4)
|
||||
expect(pattern.setStores[0].logs.debug[3]).to.equal(
|
||||
expect(pattern.setStores[0].logs.debug).to.include(
|
||||
'Part `test` is not needed. Skipping draft and setting hidden to `true`'
|
||||
)
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue