Class: AutoTest::Configuration
- Inherits:
-
Object
- Object
- AutoTest::Configuration
- Defined in:
- lib/auto_test.rb
Instance Method Summary collapse
-
#always_present(class_name, key, value) ⇒ Object
add an array of the classname, key and value of the object to be checked every cycle.
- #fixtures(*fixtures) ⇒ Object
- #get_users_from_db(user_class_name, bool) ⇒ Object
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #links_to_exclude(*links) ⇒ Object
-
#set_input(input, *values) ⇒ Object
for the name or part of the name of an input field, decide, which values to use if not set, random values matching the input type are used.
-
#set_login_attribute_names(logins, fields) ⇒ Object
set the attribute_names and fields that are needed to login the argument is a list of pairs [attribute_name, field].
- #set_login_button(text) ⇒ Object
- #set_login_data(*data) ⇒ Object
-
#set_login_path(path) ⇒ Object
set the login path.
- #set_logout_path(path) ⇒ Object
- #set_max_depth(value) ⇒ Object
- #set_max_number_of_session_links(no) ⇒ Object
- #set_no_auth ⇒ Object
- #set_number_of_sessions(number) ⇒ Object
- #set_number_of_test_runs(number) ⇒ Object
-
#set_object_dependency(child, parent, attribute_name) ⇒ Object
for all objects of class child, there has to be one object of class parent attribute_name is the column that joins the two tables.
- #set_unique_login_attribute_name(name) ⇒ Object
- #stop_at_first_error(stop_at_first_error) ⇒ Object
- #use_fixtures(bool) ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
34 35 36 37 38 39 40 |
# File 'lib/auto_test.rb', line 34 def initialize Test.initialize_test Rails.logger.level = 1 DatabaseCleaner.strategy = :truncation DatabaseCleaner.start DatabaseCleaner.clean end |
Instance Method Details
#always_present(class_name, key, value) ⇒ Object
add an array of the classname, key and value of the object to be checked every cycle
68 69 70 |
# File 'lib/auto_test.rb', line 68 def always_present(class_name, key, value) Dsl.always_present(class_name, key, value) end |
#fixtures(*fixtures) ⇒ Object
47 48 49 |
# File 'lib/auto_test.rb', line 47 def fixtures(*fixtures) Test.fixtures(fixtures) end |
#get_users_from_db(user_class_name, bool) ⇒ Object
72 73 74 |
# File 'lib/auto_test.rb', line 72 def get_users_from_db(user_class_name, bool) Dsl.get_users_from_db(user_class_name, bool) end |
#links_to_exclude(*links) ⇒ Object
51 52 53 |
# File 'lib/auto_test.rb', line 51 def links_to_exclude(*links) Dsl.links_to_exclude(*links) end |
#set_input(input, *values) ⇒ Object
for the name or part of the name of an input field, decide, which values to use if not set, random values matching the input type are used
86 87 88 |
# File 'lib/auto_test.rb', line 86 def set_input(input, *values) Dsl.set_input(input, *values) end |
#set_login_attribute_names(logins, fields) ⇒ Object
set the attribute_names and fields that are needed to login the argument is a list of pairs [attribute_name, field]
103 104 105 |
# File 'lib/auto_test.rb', line 103 def set_login_attribute_names(logins, fields) Dsl.set_login_attribute_names(logins, fields) end |
#set_login_button(text) ⇒ Object
55 56 57 |
# File 'lib/auto_test.rb', line 55 def (text) Dsl.(text) end |
#set_login_data(*data) ⇒ Object
80 81 82 |
# File 'lib/auto_test.rb', line 80 def set_login_data(*data) Dsl.set_login_data(*data) end |
#set_login_path(path) ⇒ Object
set the login path
97 98 99 |
# File 'lib/auto_test.rb', line 97 def set_login_path(path) Dsl.set_login_path(path) end |
#set_logout_path(path) ⇒ Object
115 116 117 |
# File 'lib/auto_test.rb', line 115 def set_logout_path(path) Dsl.set_logout_path(path) end |
#set_max_depth(value) ⇒ Object
59 60 61 |
# File 'lib/auto_test.rb', line 59 def set_max_depth(value) Dsl.set_max_depth(value) end |
#set_max_number_of_session_links(no) ⇒ Object
107 108 109 |
# File 'lib/auto_test.rb', line 107 def set_max_number_of_session_links(no) Dsl.set_max_number_of_session_links(no) end |
#set_no_auth ⇒ Object
111 112 113 |
# File 'lib/auto_test.rb', line 111 def set_no_auth Dsl.set_no_auth end |
#set_number_of_sessions(number) ⇒ Object
63 64 65 |
# File 'lib/auto_test.rb', line 63 def set_number_of_sessions(number) Dsl.set_number_of_sessions(number) end |
#set_number_of_test_runs(number) ⇒ Object
123 124 125 |
# File 'lib/auto_test.rb', line 123 def set_number_of_test_runs(number) Dsl.set_number_of_test_runs(number) end |
#set_object_dependency(child, parent, attribute_name) ⇒ Object
for all objects of class child, there has to be one object of class parent attribute_name is the column that joins the two tables
92 93 94 |
# File 'lib/auto_test.rb', line 92 def set_object_dependency(child, parent, attribute_name) Dsl.set_object_dependency(child, parent, attribute_name) end |
#set_unique_login_attribute_name(name) ⇒ Object
76 77 78 |
# File 'lib/auto_test.rb', line 76 def set_unique_login_attribute_name(name) Dsl.set_unique_login_attribute_name(name) end |
#stop_at_first_error(stop_at_first_error) ⇒ Object
119 120 121 |
# File 'lib/auto_test.rb', line 119 def stop_at_first_error(stop_at_first_error) Dsl.stop_at_first_error(stop_at_first_error) end |
#use_fixtures(bool) ⇒ Object
42 43 44 |
# File 'lib/auto_test.rb', line 42 def use_fixtures(bool) Test.use_fixtures(bool) end |