Based off of Mozilla Firefox Accounts server. This project constrantly rebases from either master branch with our own customizations on top of theirs.
Static server that hosts Firefox Account sign up, sign in, email verification, etc. flows.
npm install -g grunt-cli
)npm install -g phantomjs
)npm install -g bower
)cp server/config/local.json-dist server/config/local.json
npm install
npm start
It will listen on http://127.0.0.1:3030 by default.
There is quite a bit of setup to do before you can test this service, which is non-optimal, but for now:
SAUCE_USERNAME=fxa-content
SAUCE_ACCESS_KEY=ee5354a4-3d5e-47a0-84b0-0b7aaa12a720
)phantomjs --webdriver=4444
(see Prerequisites)npm start
e.g. in shell form:
export SAUCE_USERNAME=fxa-content
export SAUCE_ACCESS_KEY=ee5354a4-3d5e-47a0-84b0-0b7aaa12a720
phantomjs --webdriver=4444 &
cd fxa-auth-server
npm start &
cd ../fxa-content-server
npm start &
To run tests locally against phantomjs:
npm test
To run tests against saucelabs:
npm run-script test-remote
It is possible to run the Selenium tests against local browsers like Firefox, Chrome, and Safari.
tests/intern.js
to select the browsers to test under environments
.phantom
java -jar selenium-server-standalone-2.38.0.jar
fxa-content-server
directory, type npm test
bower update
grunt copy:strings
grunt po2json
grunt serverproc:dev
The default auth server is http://api-accounts.dev.lcip.org
. To change this,
edit server/config/*.json
on your deployed instance.
{
'fxaccount_url': 'http://your.auth.server.here.org'
}
Grunt is used to run common tasks to build, test, and run local servers.
grunt jshint
- run JSHint on client side and testing JavaScript.grunt build
- build production resources.grunt clean
- remove any built production resources.grunt test
- run local Intern tests.grunt server
- run a local server running on port 3030 with development resources.grunt server:dist
- run a local server running on port 3030 with production resources. Production resources will be built as part of the task.grunt version
- stamp a new minor version. Updates the version number and creates a new CHANGELOG.mdgrunt version:patch
- stamp a new patch version. Updates the version number and creates a new CHANGELOG.mdMPL 2.0