My Project
 All Data Structures Namespaces Functions Variables
Public Member Functions | Data Fields
CI_Unit_test Class Reference

Public Member Functions

 set_test_items ($items=array())
 
 run ($test, $expected=TRUE, $test_name= 'undefined', $notes= '')
 
 report ($result=array())
 
 use_strict ($state=TRUE)
 
 active ($state=TRUE)
 
 result ($results=array())
 
 set_template ($template)
 
 _backtrace ()
 
 _default_template ()
 
 _parse_template ()
 

Data Fields

 $active = TRUE
 
 $results = array()
 
 $strict = FALSE
 
 $_template = NULL
 
 $_template_rows = NULL
 
 $_test_items_visible = array()
 

Member Function Documentation

_backtrace ( )

Generate a backtrace

This lets us show file names and line numbers

private

Returns
array
_default_template ( )

Get Default Template

private

Returns
string
_parse_template ( )

Parse Template

Harvests the data within the template {pseudo-variables}

private

Returns
void
active (   $state = TRUE)

Make Unit testing active

Enables/disables unit testing

public

Parameters
bool
Returns
null
report (   $result = array())

Generate a report

Displays a table with the test data

public

Returns
string
result (   $results = array())

Result Array

Returns the raw result data

public

Returns
array
run (   $test,
  $expected = TRUE,
  $test_name = 'undefined',
  $notes = '' 
)

Run the tests

Runs the supplied tests

public

Parameters
mixed
mixed
string
Returns
string
set_template (   $template)

Set the template

This lets us set the template to be used to display results

public

Parameters
string
Returns
void
set_test_items (   $items = array())

Run the tests

Runs the supplied tests

public

Parameters
array
Returns
void
use_strict (   $state = TRUE)

Use strict comparison

Causes the evaluation to use === rather than ==

public

Parameters
bool
Returns
null

The documentation for this class was generated from the following file: