All contributions are welcomed!
Create an issue to report a bug, ask a question, request a new feature, etc.
All that is needed to work with this repo is Node.js and your favorite editor or IDE, although we recommend VS Code.
To build and/or work on this project:
Clone the repo, change into the directory where you cloned the directory, and then run the developer setup script
git clone https://github.com/swellaby/vsts-mirror-git-repository.git
cd vsts-mirror-git-repository
npm i
npm run test-dev
Swellaby members should create a branch within the repository, make changes there, and then submit a PR.
Outside contributors should fork the repository, make changes in the fork, and then submit a PR.
We use Mocha and Sinon to test and validate, and the tests are written using Mocha's BDD interface.
There are suites of unit tests that validate individual functions in complete isolation. Unit tests reside in the src
directory hierarchy in *.spec
files alongside the application code files that they test.
The tests can be run via the npm test
and test-dev
scripts. The test results will be displayed in the console.
Run the unit tests:
npm test
or
npm run test-dev
You must write corresponding unit tests for any code you add or modify, and all tests must pass before those changes can be merged back to the master branch.
Code coverage is generated, and enforced using Istanbuljs/nyc. The unit test suite has 100% coverage of the application source code. Code coverage will not be allowed to dip below 100%.
Code coverage results will be displayed on the terminal when the unit tests are run.
This repo uses tslint for linting the source code. tslint is executed by running the npm lint
script. The tslint configuration file can be found in the tslint.json file.
You can run tslint at any time by executing the npm lint
script:
npm run lint