feat: add check server command

This commit is contained in:
Mauricio Siu
2024-06-03 21:55:29 -06:00
parent 85fd1f2c3e
commit de871490d7
27 changed files with 5907 additions and 1 deletions

View File

@@ -0,0 +1,14 @@
import {runCommand} from '@oclif/test'
import {expect} from 'chai'
describe('check-server', () => {
it('runs check-server cmd', async () => {
const {stdout} = await runCommand('check-server')
expect(stdout).to.contain('hello world')
})
it('runs check-server --name oclif', async () => {
const {stdout} = await runCommand('check-server --name oclif')
expect(stdout).to.contain('hello oclif')
})
})

View File

@@ -0,0 +1,9 @@
import {runCommand} from '@oclif/test'
import {expect} from 'chai'
describe('hello', () => {
it('runs hello', async () => {
const {stdout} = await runCommand('hello friend --from oclif')
expect(stdout).to.contain('hello friend from oclif!')
})
})

View File

@@ -0,0 +1,9 @@
import {runCommand} from '@oclif/test'
import {expect} from 'chai'
describe('hello world', () => {
it('runs hello world cmd', async () => {
const {stdout} = await runCommand('hello world')
expect(stdout).to.contain('hello world!')
})
})

9
test/tsconfig.json Normal file
View File

@@ -0,0 +1,9 @@
{
"extends": "../tsconfig",
"compilerOptions": {
"noEmit": true
},
"references": [
{"path": ".."}
]
}