2022-09-09 20:20:38 +02:00
|
|
|
import chai from 'chai'
|
|
|
|
import { Pattern } from '../src/index.mjs'
|
2022-08-25 11:47:54 +02:00
|
|
|
|
|
|
|
const expect = chai.expect
|
2018-08-12 12:37:30 +02:00
|
|
|
|
2022-08-27 09:27:07 +02:00
|
|
|
describe('Hooks', () => {
|
2022-09-09 20:20:38 +02:00
|
|
|
it('Should contain all hooks', () => {
|
|
|
|
const pattern = new Pattern()
|
|
|
|
const h = pattern.hooks
|
2022-08-27 09:27:07 +02:00
|
|
|
const test = {
|
|
|
|
preDraft: [],
|
|
|
|
postDraft: [],
|
|
|
|
postLayout: [],
|
|
|
|
preSample: [],
|
|
|
|
postSample: [],
|
|
|
|
preRender: [],
|
|
|
|
postRender: [],
|
|
|
|
insertText: [],
|
2022-09-09 20:20:38 +02:00
|
|
|
}
|
|
|
|
expect(h).to.eql(test)
|
|
|
|
})
|
|
|
|
})
|