Register
Submit a solution
The challenge is finished.

Challenge Overview

Challenge objective

  • Write robust unit tests covering all commands and functions in Topcoder CLI

Project background

  • Topcoder is creating a command line tool to help members interact with Topcoder platform for various use cases like submitting the current directory to a challenge, retrieving submissions and artifacts etc...

Technology Stack

  • Node.js 10.x

  • Javascript

Challenge Assets

  • Source code of existing Topcoder CLI tool can be found here. Please refer to the latest commit in develop branch

  • Auth0 credentials for implementing M2M support is shared in the challenge forum which will be accessible after registration

  • User credentials to access development environment is shared in the challenge forum as well

Individual Requirements

Robust Unit tests

  • Please refer https://github.com/topcoder-platform/topcoder-cli/issues/24

  • Please use Mocha & Chai for testing and Sinon and Nock for mocking any external interactions and Nyc istanbul for generating test report

  • Please use meaningful statements while writing test cases in `it` clause

  • We expect 95%+ coverage in all aspects (Statements, Branches, Functions and Lines)

  • Test cases should be robust and do strong validation. E.g. Instead of validating that a response object exist, we need to validate the values inside the response.

  • Every test case should have proper assertion statement and shouldn’t invoke the function simply to increase the code coverage.

  • If there is a need to validate logs, it can be done by injecting the logger into the tests and pushing the logs into an array and validating the required entries later on.

  • Command to run unit tests should be `npm run test`

  • Command to run unit tests with coverage should be `npm run cov`

Important Notes:

  • Submission, Review, Appeals timeline for this challenge shorter than usual. Please pay attention to the shortened timelines

  • Please ensure that there are no lint errors and every test case pass

  • If you have any doubts, Please feel free to post it in the forum. We will be happy to resolve your queries as soon as possible.



Final Submission Guidelines

  • Create a git patch file against the latest commit in `develop` branch. Please prepare git patch file using git CLI only. Please make sure to test your patch file before submitting.

  • Create a Validation document using any format like Word, Markdown, txt file

  • Zip the patch file and Validation document and submit the zip file using the Submit link

  • After submitting, please ensure that you are able to download your submission from Online Review

ELIGIBLE EVENTS:

2020 Topcoder(R) Open

Review style

Final Review

Community Review Board

Approval

User Sign-Off

ID: 30109575