GEL Test: Typography
This application is intended to provide red/green feedback on compliance with BBC GEL standards for typography.
gel-test is built on top of Node.js.
It has further dependencies, such as CasperJS, PhantomJS and Yadda which are managed automatically via the npm tool.
To begin you will need NodeJS and npm installed on your computer. There are then two steps required to get ready to run. Best way is probably to use nvm as a Node.js installer.
gel-test can be installed as a system executable as following:
npm install -g gel-test
Assuming you have cloned the geltest-typography project repo, you can complete the installation of gel-test with the following commands:
cd geltest-typography npm install
In order for CasperJS to access test pages on the Web, it may require that proxy variables be set in your environmant (for example if you are running the application behind a proxy server).
export http_proxy="http://some.proxy.example.com:80" export HTTP_PROXY="http://some.proxy.example.com:80" export https_proxy="http://some.proxy.example.com:80" export HTTPS_PROXY="http://some.proxy.example.com:80"
See the documentation for CasperJS for more information.
gel-test requires two inputs: a feature file (written in the standard "given, when, then" style) and the URL of a fixture page to run the feature tests against.
All feature files are grouped into folders inside the
features directory. For example all feature files related to GEL Typography can be found in the
Available features are:
gel-test --fixturepage=http://bbc.github.io/gel-typography/ --features=typography
gel-test --fixturepage=http://bbc.github.io/gel-test-numbered-pagination/ --features=numbered-pagination
The MIT License (MIT)
Copyright (c) 2015, British Broadcasting Corporation
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.