- Git
- Python 3.7.7+
- Pip
Clone from this repo using the following command.
git clone https://github.com/fentonreid/SlackZulipIntegration.git
From the root directory of this project "slackZulipIntegration/" run the following command in console.
pip install -r requirements.txt
cd flaskFiles/
python flask_app.py
cd flaskFiles/
python flask_app.py PORT
To load the website simply navigate to http://localhost:PORT/
To run tests the .env file found at "tests/.env" needs to be modified.
This .env is 5 lines long and mimics the 5 integration details required for the integration to begin.
To run these files simply navigate to the "tests/runAllTests/" directory, and open a new console in this directory.
The following commands will run three of four test files.
python runFlaskSite.py
python runIntegration.py
python runMarkdown.py
The Jasmine tests are run in a different way. Similar to above we start by opening a console in the "tests/runAllTests/" directory.
python runJavascript.py
This will run a Jasmine server on port 5000 that can be accessed through the following URL, http://localhost:5000/?random=false.
To update the emoji list run the "/integration/markdown/emojis/updateEmojiList.py" file through a console using the following commands.
cd integration/markdown/emojis/
python updateEmojiList.py
Flask-SQLAlchemy is used in this project and the ORM is determined by the config option found in "flaskFiles/init.py. The following code found on line 22 of the init.py file is currently used to map to a Sqlite database termed userDetails.db.
app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///userDetails.db'
Using the documentation found here the relevant database engine can be altered.