openjio - Open a supper jio closejio - Close the jio about - Find out more help - Detailed instructions and troubleshooting
The birthday easter egg is a feature where, if a telegram command containing a specific phrase (eg "happybd", "happybirthday", "shanhousebesthouse") is repeated 10 times, the bot will repeat it once. This count is reset after 24 hours of no mentions.
Supperbot only captures messages starting with a /
When privacy mode is enabled, a bot will only be able to receive command messages after it is tagged. When another bot command is activated, the bot will no longer be able to receive command messages. For example, if haze_bot is issued a command, supperbot will not be able to receive the message /openjio even though it is a supperbot command. Supperbot can then only receive commands again when it is tagged, for example with a command /openjio@supper_bot.
Hence, the birthday easter egg feature will not work with privacy mode enabled.
This guide is meant for the WebStorm IDE by JetBrains. For other IDEs please refer to the respective setup guides.
(Alternatively, refer to Mocha - the fun, simple, flexible JavaScript test framework (mochajs.org))
- Run
npm i --g --save-dev mochaand thennpm i --save-dev nycin your terminal to install Mocha and NYC Mocha (Tool used with Mocha to show Test COde Coverage). - Navigate to
Run > Edit Configurationsfrom the menu bar to open theRun/Debug Configurationswindow. - Click on the
+icon on the top left and select Mocha. (Don't see Mocha as an Option? You'll need to add the Node.js Plug-in to WebStorm first) - Name the configuration any relevant name (e.g.
HelpersTestingSuite). - Select the Node.js interpreter used by your project (The default interpreter should be the one used by the Project - this is sufficient).
- Ensure that the Working directory is the Project directory, and the Mocha package refers to the installed Mocha package.
- User interface should be set to
bdd. - For the Test directory, choose the folder containing test suites (e.g.
test/helpersTest), and select theAll in directoryoption above it. - Click ok to complete Configuration setup.
- Test cases written in the Mocha framework within the test directory can now be run by running the configuration!
- Run
npm testcommand in terminal, if it showsError: No test cases, you're all set.
Note: Documentation for testing library can be found here:
https://nodejs.org/api/assert.html
https://mochajs.org/ (only BDD-style functions)
API_URL= BIRTHDAY_STRINGS= BOT_NAME= BOT_TOKEN= DATABASE_URL= DB_DATABASE= DB_HOST= DB_PASSWORD= DB_USER= DEBUG=
HEROKU_URL= SERVER_URL=