Class: Testgen::PrototypeWithTests

Inherits:
Prototype
  • Object
show all
Defined in:
lib/testgen/cli.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializePrototypeWithTests

initialize()

Initializes the object



13
14
15
16
17
18
# File 'lib/testgen/cli.rb', line 13

def initialize()
  # Initialize the base class
  super()
  # Create the array of tests
  @tests = []
end

Instance Attribute Details

#testsObject (readonly)

The array of tests



19
20
21
# File 'lib/testgen/cli.rb', line 19

def tests
  @tests
end

Instance Method Details

#add_tests(tests) ⇒ Object

add_tests( tests )

tests - An array of TestData objects

Adds an array of tests to the prototype



25
26
27
# File 'lib/testgen/cli.rb', line 25

def add_tests( tests )
  tests.each { |test| @tests.push( test ); }
end