Class: TestSuite
- Inherits:
-
Object
- Object
- TestSuite
- Defined in:
- lib/ui/test-suites/TestSuite.rb
Defined Under Namespace
Classes: Builder
Instance Method Summary collapse
-
#addTestCase(testCase) ⇒ Object
Function used to add a TestCase to thee TestSuite.
-
#getName ⇒ String
Retrieve the name of the TestSuite.
-
#getNumberOfTestCases ⇒ Number
Retrieve the number of TestCases within the TestSuite.
-
#initialize(name, driver) ⇒ TestSuite
constructor
A new instance of TestSuite.
-
#run ⇒ Object
Function that will invoke all test cases.
Constructor Details
#initialize(name, driver) ⇒ TestSuite
Returns a new instance of TestSuite.
4 5 6 7 8 9 10 11 12 13 14 15 |
# File 'lib/ui/test-suites/TestSuite.rb', line 4 def initialize(name, driver) if name.nil? or name.empty? raise "All TestSuites must have a name associated to them" end if driver.nil? raise "Driver must be non nil" end @name = name @driver = driver @entries = [] end |
Instance Method Details
#addTestCase(testCase) ⇒ Object
Function used to add a TestCase to thee TestSuite
19 20 21 |
# File 'lib/ui/test-suites/TestSuite.rb', line 19 def addTestCase(testCase) @entries.push(testCase) end |
#getName ⇒ String
Retrieve the name of the TestSuite
25 26 27 |
# File 'lib/ui/test-suites/TestSuite.rb', line 25 def getName() return @name end |
#getNumberOfTestCases ⇒ Number
Retrieve the number of TestCases within the TestSuite
31 32 33 |
# File 'lib/ui/test-suites/TestSuite.rb', line 31 def getNumberOfTestCases return @entries.size end |
#run ⇒ Object
Function that will invoke all test cases
36 37 38 |
# File 'lib/ui/test-suites/TestSuite.rb', line 36 def run() raise "Not yet built" end |