Update create-matrix.test.js
This commit is contained in:
parent
f56ea1e44e
commit
0de337039e
|
@ -3,13 +3,13 @@ const path = require('path')
|
||||||
const { execSync } = require('child_process')
|
const { execSync } = require('child_process')
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
fs.emptyDirSync('tests/__data__/temp')
|
fs.emptyDirSync('tests/__data__/output')
|
||||||
|
|
||||||
fs.copyFileSync('tests/__data__/input/database/streams.db', 'tests/__data__/temp/streams.db')
|
fs.copyFileSync('tests/__data__/input/database/streams.db', 'tests/__data__/output/streams.db')
|
||||||
})
|
})
|
||||||
|
|
||||||
it('can create valid matrix', () => {
|
it('can create valid matrix', () => {
|
||||||
const result = execSync('DB_DIR=tests/__data__/temp node scripts/commands/create-matrix.js', {
|
const result = execSync('DB_DIR=tests/__data__/output node scripts/commands/create-matrix.js', {
|
||||||
encoding: 'utf8'
|
encoding: 'utf8'
|
||||||
})
|
})
|
||||||
expect(result).toBe('::set-output name=matrix::{"cluster_id":[1,3]}\n')
|
expect(result).toBe('::set-output name=matrix::{"cluster_id":[1,3]}\n')
|
||||||
|
|
Loading…
Reference in New Issue