now works as intended
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
import { expect, tap } from 'tapbundle'
|
||||
import * as path from 'path'
|
||||
|
||||
import * as smartscaf from '../dist/index'
|
||||
|
||||
@ -25,4 +26,8 @@ tap.test('ask cli', async () => {
|
||||
await testScafTemplate.askCliForMissingVariables()
|
||||
})
|
||||
|
||||
tap.test('should output ready rendered template', async () => {
|
||||
await testScafTemplate.writeToDisk(path.resolve('./test/test_output'))
|
||||
})
|
||||
|
||||
tap.start()
|
||||
|
2
test/test_output/defaults.yml
Normal file
2
test/test_output/defaults.yml
Normal file
@ -0,0 +1,2 @@
|
||||
templateVar1: from default yaml
|
||||
templateVar2: this is another value from yml
|
3
test/test_output/template1.md
Normal file
3
test/test_output/template1.md
Normal file
@ -0,0 +1,3 @@
|
||||
# this is a from default yaml
|
||||
# this is a this is another value from yml
|
||||
# this is a undefined variable
|
3
test/test_output/template2.md
Normal file
3
test/test_output/template2.md
Normal file
@ -0,0 +1,3 @@
|
||||
# this is a from default yaml
|
||||
# this is a this is another value from yml
|
||||
# this is a undefined variable
|
1
test/test_output/template3.md
Normal file
1
test/test_output/template3.md
Normal file
@ -0,0 +1 @@
|
||||
# some undefined variable
|
Reference in New Issue
Block a user