FIT
[ class tree: FIT ] [ index: FIT ] [ all elements ]

Class: Testing_FIT_Fixture

Source Location: /Testing_FIT-0.2.2/Fixture.php

Class Overview


FIT Fixture base class


Author(s):

Version:

  • 0.1.1

Variables

Methods


Child classes:

Testing_FIT_Fixture_Summary
FIT Fixture: Summary
Testing_FIT_Fixture_Column
FIT Fixture: ColumnFixture
Testing_FIT_Fixture_Primitive
FIT Fixture: PrimitiveFixture
Testing_FIT_Fixture_Row
FIT Fixture: Row
Testing_FIT_Fixture_Action
FIT Fixture: ActionFixture
Music_Browser
FIT Fixture

Inherited Variables

Inherited Methods


Class Details

[line 25]
FIT Fixture base class
  • Version: 0.1.1


[ Top ]


Class Variables

$_columnBindings =

[line 31]

column bindings
  • Access: protected

Type:   object


[ Top ]

$_columnFilter = array()

[line 37]

column filter
  • Access: protected

Type:   array


[ Top ]

$_defaultFilter =  null

[line 43]

default filter
  • Access: protected

Type:   object


[ Top ]

$_typeDictionary = array()

[line 50]

type dictionary to figure out which filter to be used
  • Deprecated: please use proper doc comments to tell what type things are
  • Access: protected

Type:   array


[ Top ]



Method Detail

__construct (Constructor)   [line 62]

Testing_FIT_Fixture __construct( )

constructor
  • Access: public

Overridden in child classes as:

Testing_FIT_Fixture_Summary::__construct()
constructor

[ Top ]

camel   [line 328]

string camel( $src, string $string)

CamelCaseString auxiliary function
  • Access: public

Parameters:

string   $string   — 
   $src   — 

[ Top ]

doCell   [line 159]

boolean doCell( Testing_FIT_Node $node, object $cell)

process a single cell

Generic processing of a table cell. Well, this function just ignores cells.

This method may be overwritten by a subclass (ColumnFixture)

  • Return: true on success
  • Access: public

Overridden in child classes as:

Math_ArithmeticFixture::doCell()
process a single cell
Testing_FIT_Fixture_Row::doCell()
match rows

Parameters:

object   $cell   —  A parse object
Testing_FIT_Node   $node   — 

[ Top ]

doCells   [line 131]

boolean doCells( Testing_FIT_Node $node)

process cells

Generic processing of all upcoming cells. Actually, this method just iterates through them and delegates to doCell()

This method may be overwritten by a subclass (ActionFixture)


Overridden in child classes as:

Testing_FIT_Fixture_Summary::doCells()
process cells
Testing_FIT_Fixture_Column::doCells()
process a single cell
Testing_FIT_Fixture_Row::doCells()
match cells
Testing_FIT_Fixture_Action::doCells()
process cells

Parameters:

object   $node   — 

[ Top ]

doRow   [line 114]

boolean doRow( Testing_FIT_Node $node)

iterate through cells

Overridden in child classes as:

Testing_FIT_Fixture_Column::doRow()
Process a table's row

Parameters:

object   $node   — 

[ Top ]

doRows   [line 92]

boolean doRows( Testing_FIT_Node $node)

iterate through rows

Overridden in child classes as:

Testing_FIT_Fixture_Summary::doRows()
iterate through table
Testing_FIT_Fixture_Column::doRows()
bind columsn to fixture and start row iterator
Math_ArithmeticFixture::doRows()
iterate through rows but skip the first one
Testing_FIT_Fixture_Row::doRows()
bind columsn to fixture and start row iterator

Parameters:

object   $node   — 

[ Top ]

doTable   [line 80]

boolean doTable( Testing_FIT_Node $node)

iterate through table

Parameters:

object   $node   — 

[ Top ]

getType   [line 223]

string getType( $name)

receive member variable's type specification

Use the helper property $_typeDictionary to figure out what type a variable is.

Type is one of:

  • integer
  • string
  • array
  • object
  • object:CLASSNAME
  • callable

  • Todo: Improve type detection and combine with filters
  • Access: public

Parameters:

   $name   — 

[ Top ]

loadFixture   [line 178]

object Fixture loadFixture( string $fixtureName)

load a fixture by java-stylish name (dot-separated)

A fixture name might be something like: eg.net.Simulator. This will load eg/net/Simulator.php and instanciates the class eg_net_Simulator. The path name is realtive to the basic fixture dir.

It also supports loading standard fixtures. They are recognized by the prefix: "fit." Those fixtures are maped to the corresponding class.

  • Access: public

Parameters:

string   $fixtureName   —  fixtureName

[ Top ]

_bind   [line 291]

boolean _bind( Testing_FIT_Node $node)

bind columns of table header to functions and properties
  • Return: true on success
  • Access: protected

Parameters:

object   $node   — 

[ Top ]

_checkCell   [line 270]

boolean _checkCell( object $node, mixec $actual)

check a cell's actual against expected value

This uses type filter to create PHP-a-like data before comparision

  • Return: true if actual result matches
  • Access: protected

Parameters:

object   $node   — 
mixec   $actual   —  the current value to check against for

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:09:48 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.