Development
- Make a local clone of this repo:
git clone git@github.com:Palindrom/Palindrom.git
- Go to the directory:
cd Palindrom
- Install the local dependencies:
npm install
- Start the development server:
npm run serve
- Bundle by calling
npm run build
in your shell, ornpm run build-watch
to automatically rebuild after every file change - Open the test suite: http://localhost:5000/test/MochaSpecRunner.html
Updating documentation
Everything in docs
folder is automatically fetched by the website and each MD file is considered a documentation section. Sections are sorted alphabetically; it's recommended to prefix your file with a numeric ordering index. Eg. (01-installation.md
, 02-development.md
..etc).
Releases
To release new version run
npm version <patch|minor|major> # to replace version in files and tag the repo
git push && git push --tags
...
npm publish
Testing
You can test Palindrom using three methods depending on your need (what you've modified):
- CLI testing: it is perfect for testing Palindrom only (as opposed to testing Palindrom + PalindromDOM). It's the fastest and the easiest to run, all you need to do is run:
npm run test-node
-
Local browser testing: This allows you to test (Palindrom + PalindromDOM), you can run it by following steps 4, 5, and 6 from Development section.
-
SauceLabs CLI Testing: This runs in the CLI, but it needs SauceLabs credentials, and Selenium needs to be running, to run it:
-
Install Sauce Connect.
-
Add your
SAUCE_USERNAME
andSAUCE_ACCESS_KEY
environment variables to your machine. -
Connect to SauceLabs using the command
sc /u %SAUCE_USERNAME% /k %SAUCE_ACCESS_KEY%
wheresc
is the executable you get when you download Sauce Connect. -
Start a web server
npm run serve
-
In project's root folder, run
npm run test-sauce
-
To run all CLI tests together, run:
npm run test