Skip to content

Commit

Permalink
Merge pull request #9 from iiddoo/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
iiddoo committed Sep 10, 2018
2 parents 225e3e3 + b855817 commit a46b645
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
8 changes: 4 additions & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ module.exports = (user, appID, safe) => {
// validate executable file
validateExe();
// set command string
//const cmd = command(user, appID, safe);
const cmd = command(user, appID, safe);
// execute shell command with parameters
// validate result
resolve('password');
} catch (error) {
reject(error);
} catch (error) {
reject(error);
}
});
};
};
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@iiddoo/aim-password-retrieve",
"version": "2.1.0",
"version": "2.1.1",
"description": "Retrieve password for user.",
"main": "index.js",
"scripts": {
Expand Down
4 changes: 4 additions & 0 deletions test/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ const index = require('../index');
const { expect } = require('chai');

describe('Index', ()=> {
it('Should throw error', done => {
expect(index()).to.throw
done()
});
it('Should return password', async () => {
const pwd = await index('user', 'my_appID', 'my_safe');
expect(pwd).to.be.a('string');
Expand Down

0 comments on commit a46b645

Please sign in to comment.