Skip to content
A digital assistant IRC bot
Branch: master
Clone or download
Latest commit 5627675 Apr 8, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
lib
test
.gitignore
.travis.yml
LICENSE-MIT
README.md
package.json
sectery.js

README.md

Sectery

Build status Coverage status

Usage

Install the dependencies:

npm install

Fire it up:

node sectery

Development

Run the tests

npm install
npm test

Observe that they all pass.

Add a new test

For the feature you'd like to develop, write a new test for it in test/sectery_test.js:

describe('message listeners', function () {

  // ...

  testIO('emoji', 'table flip', '╯°□°)╯︵ ┻━┻');

});

Run the tests again

npm test

Observe that your new test fails.

Make your test pass

lib/listeners/message/emoji.js:

'use strict';

function messageListener(db, from, channel, message) {
  if (/table\s*flip/.test(message) || /flip\s*table/.test(message)) {
    return [ { to: channel, message: '╯°□°)╯︵ ┻━┻' } ];
  }
}

module.exports = messageListener;
You can’t perform that action at this time.