No description
- JavaScript 97.6%
- Gherkin 2.4%
- applicationinsights 3.7 -> 3.17, mocha 11 -> 12 (moved to devDependencies), @cucumber/cucumber 12 -> 13, eslint/@eslint/js 9 -> 10, globals 16 -> 17 - Remove unused eslint-plugin-jest and @types/jest (tests use mocha; the plugin was not referenced in eslint.config.mjs and blocked eslint 10) - Replace unmaintained cucumber-junit and mocha-junit-reporter (incompatible with mocha 12) with the built-in cucumber junit and mocha xunit reporters - Override glob and minimatch to patched versions npm audit: 58 -> 0 vulnerabilities. Supersedes Dependabot PRs #50, #51, #53-#57. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .forgejo/workflows | ||
| .vscode | ||
| Battleship_Tests | ||
| GameController | ||
| GameController_ATDD | ||
| GameController_Tests | ||
| TelemetryClient | ||
| .gitignore | ||
| .gitlab-ci.yml | ||
| ai.js | ||
| battleship.js | ||
| buildpipeline.yml | ||
| eslint.config.mjs | ||
| index.js | ||
| package-lock.json | ||
| package.json | ||
| README.md | ||
Battleship NodeJs
A simple game of Battleship, written in NodeJs. The purpose of this repository is to serve as an entry point into coding exercises and it was especially created for scrum.orgs Applying Professional Scrum for Software Development course (www.scrum.org/apssd). The code in this repository is unfinished by design.
Getting started
To edit and debug this project, you can use Visual Studio Code or any other suitable editor. You might want to install these extensions to better support this project in VSCode:
- Mocha Test Explorer https://marketplace.visualstudio.com/items?itemName=hbenl.vscode-mocha-test-adapter
- Cucumber (Gherkin) Full Support https://marketplace.visualstudio.com/items?itemName=alexkrechik.cucumberautocomplete
Run locally
Install packages
npm install
Run battleship
npm start
Or alternatively:
node index.js
Execute tests
Execute all tests
npm test
Execute Mocha tests only
mocha './**/*Tests.js'
Execute Cucumber-js tests only
./node_modules/.bin/cucumber-js .\GameController_ATDD
Docker
To run and test the project in a container, use these steps:
docker run -it -v ${PWD}:/battleship -w /battleship node bash
npm install
npm test
npm start