Class Tester

A class to run tests.

Info:

  • License: MIT
  • Author: Richard Voelker

Fields

Tester.inputOne Checks to see if two items are equal to one another.

Methods

Tester.new (self, name) Create a new Tester to begin running tests.
Tester.AddTest (self, description, testFn) Add a new test to be run.
Tester.RunTests (self) Run all of the tests that have been added and print the results.


Fields

Tester.inputOne
Checks to see if two items are equal to one another.
  • inputOne The left hand side of the equality operator.
  • inputTwo The right hand side of the equality operator.

Methods

Tester.new (self, name)
Create a new Tester to begin running tests.

Parameters:

Tester.AddTest (self, description, testFn)
Add a new test to be run.

Parameters:

  • self Tester
  • description string

    The description of what the test

    is testing.
    
  • testFn function

    The function that runs the test. It

    should return an error message if the test failed, or nil if
    it passed.
    
Tester.RunTests (self)
Run all of the tests that have been added and print the results.

Parameters:

generated by LDoc 1.4.3 Last updated 2016-07-26 17:10:04