Skip to content

Commit

Permalink
Fix travis
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Feb 11, 2017
1 parent b758791 commit b51ea53
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 10 deletions.
2 changes: 1 addition & 1 deletion lib/cli.js
Expand Up @@ -17,7 +17,7 @@ const Router = require('./router');
const gens = list(process.argv.slice(2));

/* eslint new-cap: 0, no-extra-parens: 0 */
const tabtab = new Tabtab.Commands({
const tabtab = new Tabtab.Commands.default({
name: 'yo',
completer: 'yo-complete'
});
Expand Down
2 changes: 1 addition & 1 deletion lib/completion/completer.js
Expand Up @@ -65,7 +65,7 @@ class Completer {
*/
item(desc, prefix) {
prefix = prefix || '';
return function (item) {
return item => {
const name = typeof item === 'string' ? item : item.name;
desc = typeof item !== 'string' && item.description ? item.description : desc;
desc = desc.replace(/^#?\s*/g, '');
Expand Down
18 changes: 10 additions & 8 deletions package.json
Expand Up @@ -62,7 +62,7 @@
"root-check": "^1.0.0",
"sort-on": "^1.0.0",
"string-length": "^1.0.0",
"tabtab": "^2.2.2",
"tabtab": "^1.3.2",
"titleize": "^1.0.0",
"update-notifier": "^1.0.3",
"user-home": "^2.0.0",
Expand Down Expand Up @@ -100,12 +100,14 @@
},
"xo": {
"space": true,
"overrides": [{
"files": "test/**",
"envs": [
"node",
"mocha"
]
}]
"overrides": [
{
"files": "test/**",
"envs": [
"node",
"mocha"
]
}
]
}
}
2 changes: 2 additions & 0 deletions test/completion.js
Expand Up @@ -42,6 +42,8 @@ describe('Completion', () => {
return;
}

console.log('s', err, out);

assert.ok(/-f/.test(out));
assert.ok(/--force/.test(out));
assert.ok(/--version/.test(out));
Expand Down

0 comments on commit b51ea53

Please sign in to comment.