Commit c9f1e02a authored by Eirik Alvær's avatar Eirik Alvær
Browse files

added method to get parameters for command

parent 108ac07b
...@@ -252,6 +252,13 @@ function CommandExecutor() { ...@@ -252,6 +252,13 @@ function CommandExecutor() {
/*jslint sub: true */ /*jslint sub: true */
return helpTexts[command]["shortDescription"]; return helpTexts[command]["shortDescription"];
} }
},
getSyntax: function (command) {
if (helpTexts[command]) {
/*jslint sub: true */
return helpTexts[command]["syntax"];
}
} }
}; };
} }
...@@ -91,4 +91,12 @@ describe('Tests', function () { ...@@ -91,4 +91,12 @@ describe('Tests', function () {
done(); done();
}); });
}); });
describe('#getParamters', function () {
it('should return the parameters for given command', function (done) {
var result = ce.getParamters("correlate");
assert(result.length > 5, "parameters for correlate is too short");
done();
});
});
}); });
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment