Software Engineering for Smart Data Analytics & Smart Data Analytics for Software Engineering

User Tools

Site Tools

Command disabled: backlink

Testing Framework / Code Coverage


  • Installation
    • Prerequisite: Installed node.js/npm
    • Command: npm install -g mocha
  • Running
    • Prerequisite: test.js in current folder
    • node [PATH TO NODE_MODULES]\mocha\bin\mocha
      • Example: node C:\Users\molitor\AppData\Roaming\npm\node_modules\mocha\bin\mocha
  • Specification
  • All tests need to be located in a root folder 'test' (case sensitive) or any of its subfolders.
  • Only .js files are executed.
  • Use the --recursive option to execute the entire test suite inside test.
  • Use --reporter <name> options for a differently structured output (including performance benchmarks).
    • --reporters for all available reporter types
    • Example: --reporter json


teaching/labs/xp/2012b/testing-framework.txt · Last modified: 2018/05/09 01:59 (external edit)

SEWiki, © 2019