Git Product home page Git Product logo

continua11y-dashboard's Introduction

Continua11y

Build Status Test Coverage Code Climate Continua11y

A dashboard for continuous integration of accessibility. It uses pa11y, a web accessibility tool in an environment like CI to generate accessibility statistics for pages on a site. The dashboard also provides accessibility badges to install on your repo!

Contributing

See CONTRIBUTING for additional information.

Development work

This is an express application written in node.js. Install all dependencies via:

npm install

This is a basic express app, so there are a couple of npm scripts to make reloading the application while working almost seamless.

To reload the general application code while running a server use this script:

npm run dev

Unfortunately, rerunning the sass is a different process. To compile the css takes an addition script:

npm run dev_sass

Running both those scripts while developing can give a good reloadable environment.

Environmental variables

The application integrates with github and requires environmental variables. Development and test use the great module dotenv to load environmental variables for the test run.

To get started copy the sample file to .env.

cp .env-sample .env

A script on application creation checks to make sure require environmental variables are present.

Database

Database is postgres and you need to create these databases outside the application scripts:

createdb continua11y-dashboard-test # for test env
createdb continua11y-dashboard-development # for development

The database sql abstraction is provided by the module knex, and other database configuration options can be found in the ./knexfile.js.

Migrations are also handled by this module.

Creating a new migration can be done via:

node_modules/.bin/knex migrate:make ___migration_name_here___

Migrate the databases via

NODE_ENV=development node_modules/.bin/knex migrate:latest
NODE_ENV=test        node_modules/.bin/knex migrate:latest

Testing

Acceptance tests use the npm module zombie and are located in the test/acceptance directory.

Unit and integration tests are in the test directory and organized to mirror the app directory.

All types of tests use mocha as the test runner.

Run tests via npm test. Under the covers that runs mocha recursively on the test directory.

See mocha documentation for details about running tests in isolation or running a single file.

Starting the app

There is a script for that:

npm start

Getting your badge

SVG badges are available from the dashboard via a url: /badges/:repository_owner/:repository_name/:branch'. For example the path for this repository would be /badges/18F/continua11y-dashboard/master`.

Public domain

This project is in the worldwide public domain. As stated in CONTRIBUTING:

This project is in the public domain within the United States, and copyright and related rights in the work worldwide are waived through the CC0 1.0 Universal public domain dedication.

All contributions to this project will be released under the CC0 dedication. By submitting a pull request, you are agreeing to comply with this waiver of copyright interest.

continua11y-dashboard's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.