Files
dsabot/__tests__/commands/Roll.js
TobenderZephyr ba63be64dd merge dev branch (more tests) (#47)
* more tests and bugfixes on spells

* linting
2021-05-06 19:35:58 +00:00

15 lines
510 B
JavaScript

require('module-alias/register');
require('babel-plugin-rewire');
const command = require('@Commands/Roll');
//const exec = command.__get__('exec');
describe('roll command', () => {
const reply = jest.fn(str => str);
const message = { author: { tag: 'test' }, reply: reply };
it('should not return anything without correct arguments', () => {
const args = ['1w6'];
expect(command.exec(message, args)).resolves.toBeUndefined();
expect(reply).toHaveBeenCalled();
});
});