mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-09 08:30:06 -04:00
Replace -- with --- in npm commands
Resolves https://github.com/iptv-org/epg/issues/2354 Details: https://github.com/npm/cli/issues/3136
This commit is contained in:
parent
9f89cd2160
commit
28c8e3d74f
203 changed files with 607 additions and 607 deletions
|
@ -24,7 +24,7 @@ describe('channels:editor', () => {
|
|||
}
|
||||
|
||||
try {
|
||||
const cmd = `${ENV_VAR} npm run channels:editor -- tests/__data__/output/channels.xml`
|
||||
const cmd = `${ENV_VAR} npm run channels:editor --- tests/__data__/output/channels.xml`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
} catch (error) {
|
||||
expect((error as ExecError).status).toBe(1)
|
||||
|
|
|
@ -9,7 +9,7 @@ describe('channels:lint', () => {
|
|||
it('will show a message if the file contains a syntax error', () => {
|
||||
try {
|
||||
const cmd =
|
||||
'npm run channels:lint -- --channels=tests/__data__/input/channels-lint/channels-lint.channels.xml'
|
||||
'npm run channels:lint --- --channels=tests/__data__/input/channels-lint/channels-lint.channels.xml'
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
process.exit(1)
|
||||
} catch (error) {
|
||||
|
|
|
@ -13,7 +13,7 @@ beforeEach(() => {
|
|||
describe('channels:parse', () => {
|
||||
it('can parse channels', () => {
|
||||
const cmd =
|
||||
'npm run channels:parse -- --config=tests/__data__/input/channels-parse/channels-parse.config.js --output=tests/__data__/output/channels.xml'
|
||||
'npm run channels:parse --- --config=tests/__data__/input/channels-parse/channels-parse.config.js --output=tests/__data__/output/channels.xml'
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(content('tests/__data__/output/channels.xml')).toEqual(
|
||||
|
|
|
@ -14,7 +14,7 @@ if (os.platform() === 'win32') {
|
|||
describe('channels:validate', () => {
|
||||
it('will show a message if the file contains a duplicate', () => {
|
||||
try {
|
||||
const cmd = `${ENV_VAR} npm run channels:validate -- --channels=tests/__data__/input/channels-validate/duplicate.channels.xml`
|
||||
const cmd = `${ENV_VAR} npm run channels:validate --- --channels=tests/__data__/input/channels-validate/duplicate.channels.xml`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
process.exit(1)
|
||||
} catch (error) {
|
||||
|
@ -39,7 +39,7 @@ tests/__data__/input/channels-validate/duplicate.channels.xml
|
|||
|
||||
it('will show a message if the file contains a channel with wrong xmltv_id', () => {
|
||||
try {
|
||||
const cmd = `${ENV_VAR} npm run channels:validate -- --channels=tests/__data__/input/channels-validate/wrong_xmltv_id.channels.xml`
|
||||
const cmd = `${ENV_VAR} npm run channels:validate --- --channels=tests/__data__/input/channels-validate/wrong_xmltv_id.channels.xml`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
process.exit(1)
|
||||
} catch (error) {
|
||||
|
|
|
@ -17,7 +17,7 @@ beforeEach(() => {
|
|||
|
||||
describe('epg:grab', () => {
|
||||
it('can grab epg by site name', () => {
|
||||
const cmd = `${ENV_VAR} npm run grab -- --site=example.com --output=tests/__data__/output/guide.xml`
|
||||
const cmd = `${ENV_VAR} npm run grab --- --site=example.com --output=tests/__data__/output/guide.xml`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(content('tests/__data__/output/guide.xml')).toEqual(
|
||||
|
@ -26,7 +26,7 @@ describe('epg:grab', () => {
|
|||
})
|
||||
|
||||
it('can grab epg with multiple channels.xml files', () => {
|
||||
const cmd = `${ENV_VAR} npm run grab -- --channels=tests/__data__/input/epg-grab/sites/**/*.channels.xml --output=tests/__data__/output/guide.xml`
|
||||
const cmd = `${ENV_VAR} npm run grab --- --channels=tests/__data__/input/epg-grab/sites/**/*.channels.xml --output=tests/__data__/output/guide.xml`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(content('tests/__data__/output/guide.xml')).toEqual(
|
||||
|
@ -35,7 +35,7 @@ describe('epg:grab', () => {
|
|||
})
|
||||
|
||||
it('can grab epg with gzip option enabled', async () => {
|
||||
const cmd = `${ENV_VAR} npm run grab -- --channels=tests/__data__/input/epg-grab/sites/**/*.channels.xml --output=tests/__data__/output/guide.xml --gzip`
|
||||
const cmd = `${ENV_VAR} npm run grab --- --channels=tests/__data__/input/epg-grab/sites/**/*.channels.xml --output=tests/__data__/output/guide.xml --gzip`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(content('tests/__data__/output/guide.xml')).toEqual(
|
||||
|
@ -49,7 +49,7 @@ describe('epg:grab', () => {
|
|||
})
|
||||
|
||||
it('can grab epg with wildcard as output', () => {
|
||||
const cmd = `${ENV_VAR} npm run grab -- --channels=tests/__data__/input/epg-grab/sites/example.com/example.com.channels.xml --output=tests/__data__/output/guides/{lang}/{site}.xml`
|
||||
const cmd = `${ENV_VAR} npm run grab --- --channels=tests/__data__/input/epg-grab/sites/example.com/example.com.channels.xml --output=tests/__data__/output/guides/{lang}/{site}.xml`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(content('tests/__data__/output/guides/en/example.com.xml')).toEqual(
|
||||
|
@ -62,7 +62,7 @@ describe('epg:grab', () => {
|
|||
})
|
||||
|
||||
it('can grab epg then language filter enabled', () => {
|
||||
const cmd = `${ENV_VAR} npm run grab -- --channels=tests/__data__/input/epg-grab/sites/example.com/example.com.channels.xml --output=tests/__data__/output/guides/{lang}/{site}.xml --lang=fr`
|
||||
const cmd = `${ENV_VAR} npm run grab --- --channels=tests/__data__/input/epg-grab/sites/example.com/example.com.channels.xml --output=tests/__data__/output/guides/{lang}/{site}.xml --lang=fr`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(content('tests/__data__/output/guides/fr/example.com.xml')).toEqual(
|
||||
|
@ -71,7 +71,7 @@ describe('epg:grab', () => {
|
|||
})
|
||||
|
||||
it('can grab epg using custom channels list', () => {
|
||||
const cmd = `${ENV_VAR} npm run grab -- --channels=tests/__data__/input/epg-grab/custom.channels.xml --output=tests/__data__/output/guide.xml`
|
||||
const cmd = `${ENV_VAR} npm run grab --- --channels=tests/__data__/input/epg-grab/custom.channels.xml --output=tests/__data__/output/guide.xml`
|
||||
execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(content('tests/__data__/output/guide.xml')).toEqual(
|
||||
|
@ -80,7 +80,7 @@ describe('epg:grab', () => {
|
|||
})
|
||||
|
||||
it('it will raise an error if the timeout is exceeded', () => {
|
||||
const cmd = `${ENV_VAR} npm run grab -- --channels=tests/__data__/input/epg-grab/custom.channels.xml --output=tests/__data__/output/guide.xml --timeout=0`
|
||||
const cmd = `${ENV_VAR} npm run grab --- --channels=tests/__data__/input/epg-grab/custom.channels.xml --output=tests/__data__/output/guide.xml --timeout=0`
|
||||
const stdout = execSync(cmd, { encoding: 'utf8' })
|
||||
|
||||
expect(stdout).toContain('ERR: Connection timeout')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue