Skip to content
This repository has been archived by the owner on Aug 22, 2023. It is now read-only.

Commit

Permalink
test: fixed tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx committed Jan 28, 2018
1 parent abe2e56 commit 61f1ca7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -225,8 +225,10 @@ export class Config implements IConfig {
this.errlog = path.join(this.cacheDir, 'error.log')

this.tsconfig = await this._tsConfig()
this.commandsDir = path.join(this.root, this.pjson.dxcli.commands)
this.commandsDirTS = await this._tsPath(this.pjson.dxcli.commands)
if (this.pjson.dxcli.commands) {
this.commandsDir = path.join(this.root, this.pjson.dxcli.commands)
this.commandsDirTS = await this._tsPath(this.pjson.dxcli.commands)
}
this.hooks = _.mapValues(this.pjson.dxcli.hooks || {}, h => _.castArray(h).map(h => path.join(this.root, h)))
this.hooksTS = await this._hooks()
if (typeof this.pjson.dxcli.plugins === 'string') {
Expand Down
2 changes: 1 addition & 1 deletion test/config.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ describe('PluginConfig', () => {
.add('config', testPlugin('heroku-run'))
.end('heroku-run has properties', ({config}) => {
expect(config.config).to.include({
commandsDir: undefined
// commandsDir: undefined
})
})

Expand Down

0 comments on commit 61f1ca7

Please sign in to comment.