mirror of https://github.com/iptv-org/iptv
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
512 B
JavaScript
17 lines
512 B
JavaScript
const fs = require('fs-extra')
|
|
const path = require('path')
|
|
const { execSync } = require('child_process')
|
|
|
|
beforeEach(() => {
|
|
fs.emptyDirSync('tests/__data__/output')
|
|
|
|
fs.copyFileSync('tests/__data__/input/database/streams.db', 'tests/__data__/output/streams.db')
|
|
})
|
|
|
|
it('can create valid matrix', () => {
|
|
const result = execSync('DB_DIR=tests/__data__/output node scripts/commands/create-matrix.js', {
|
|
encoding: 'utf8'
|
|
})
|
|
expect(result).toBe('::set-output name=matrix::{"cluster_id":[1,3]}\n')
|
|
})
|