Class: QaServer::Configuration
- Inherits:
-
Object
- Object
- QaServer::Configuration
- Defined in:
- lib/qa_server/configuration.rb
Instance Attribute Summary collapse
-
#display_historical_datatable ⇒ Object
writeonly
Displays a datatable of historical test data when true.
-
#display_historical_graph ⇒ Object
writeonly
Displays a graph of historical test data when true.
-
#display_performance_datatable ⇒ Object
writeonly
Displays a datatable of performance test data when true.
-
#display_performance_graph ⇒ Object
writeonly
Displays a graph of performance test data when true.
-
#navmenu_extra_leftitems ⇒ Object
Additional menu items to add to the main navigation menu's set of left justified menu items.
- #performance_datatable_default_time_period ⇒ Object
- #performance_datatable_max_threshold ⇒ Object
- #performance_datatable_warning_threshold ⇒ Object
- #performance_graph_default_time_period ⇒ Object
- #performance_graph_load_color ⇒ Object
- #performance_normalization_color ⇒ Object
- #performance_retrieve_color ⇒ Object
- #performance_y_axis_max ⇒ Object
Instance Method Summary collapse
- #display_historical_datatable? ⇒ Boolean
- #display_historical_graph? ⇒ Boolean
- #display_performance_datatable? ⇒ Boolean
- #display_performance_graph? ⇒ Boolean
-
#navmenu_presenter ⇒ Object
Get the one and only instance of the navigation menu presenter used to construct the main navigation menu.
- #performance_tracker ⇒ Object
Instance Attribute Details
#display_historical_datatable=(value) ⇒ Object (writeonly)
Displays a datatable of historical test data when true
14 15 16 |
# File 'lib/qa_server/configuration.rb', line 14 def display_historical_datatable=(value) @display_historical_datatable = value end |
#display_historical_graph=(value) ⇒ Object (writeonly)
Displays a graph of historical test data when true
6 7 8 |
# File 'lib/qa_server/configuration.rb', line 6 def display_historical_graph=(value) @display_historical_graph = value end |
#display_performance_datatable=(value) ⇒ Object (writeonly)
Displays a datatable of performance test data when true
67 68 69 |
# File 'lib/qa_server/configuration.rb', line 67 def display_performance_datatable=(value) @display_performance_datatable = value end |
#display_performance_graph=(value) ⇒ Object (writeonly)
Displays a graph of performance test data when true
22 23 24 |
# File 'lib/qa_server/configuration.rb', line 22 def display_performance_graph=(value) @display_performance_graph = value end |
#navmenu_extra_leftitems ⇒ Object
Additional menu items to add to the main navigation menu's set of left justified menu items
101 102 103 |
# File 'lib/qa_server/configuration.rb', line 101 def end |
#performance_datatable_default_time_period ⇒ Object
76 77 78 |
# File 'lib/qa_server/configuration.rb', line 76 def performance_datatable_default_time_period @performance_datatable_default_time_period ||= :year end |
#performance_datatable_max_threshold ⇒ Object
83 84 85 |
# File 'lib/qa_server/configuration.rb', line 83 def performance_datatable_max_threshold @performance_datatable_max_threshold ||= 1500 end |
#performance_datatable_warning_threshold ⇒ Object
90 91 92 |
# File 'lib/qa_server/configuration.rb', line 90 def performance_datatable_warning_threshold @performance_datatable_warning_threshold ||= 1000 end |
#performance_graph_default_time_period ⇒ Object
61 62 63 |
# File 'lib/qa_server/configuration.rb', line 61 def performance_graph_default_time_period @performance_graph_default_time_period ||= :month end |
#performance_graph_load_color ⇒ Object
46 47 48 |
# File 'lib/qa_server/configuration.rb', line 46 def performance_graph_load_color @performance_graph_load_color ||= '#E8DCD3' end |
#performance_normalization_color ⇒ Object
54 55 56 |
# File 'lib/qa_server/configuration.rb', line 54 def performance_normalization_color @performance_normalization_color ||= '#CCBE9F' end |
#performance_retrieve_color ⇒ Object
38 39 40 |
# File 'lib/qa_server/configuration.rb', line 38 def performance_retrieve_color @performance_retrieve_color ||= '#ABC3C9' end |
#performance_y_axis_max ⇒ Object
30 31 32 |
# File 'lib/qa_server/configuration.rb', line 30 def performance_y_axis_max @performance_y_axis_max ||= 4000 end |
Instance Method Details
#display_historical_datatable? ⇒ Boolean
15 16 17 18 |
# File 'lib/qa_server/configuration.rb', line 15 def display_historical_datatable? return @display_historical_datatable unless @display_historical_datatable.nil? @display_historical_datatable = true end |
#display_historical_graph? ⇒ Boolean
7 8 9 10 |
# File 'lib/qa_server/configuration.rb', line 7 def display_historical_graph? return @display_historical_graph unless @display_historical_graph.nil? @display_historical_graph = false end |
#display_performance_datatable? ⇒ Boolean
68 69 70 71 |
# File 'lib/qa_server/configuration.rb', line 68 def display_performance_datatable? return @display_performance_datatable unless @display_performance_datatable.nil? @display_performance_datatable = true end |
#display_performance_graph? ⇒ Boolean
23 24 25 26 |
# File 'lib/qa_server/configuration.rb', line 23 def display_performance_graph? return @display_performance_graph unless @display_performance_graph.nil? @display_performance_graph = false end |
#navmenu_presenter ⇒ Object
Get the one and only instance of the navigation menu presenter used to construct the main navigation menu. To extend, set additional navigation menu items using #navmenu_extra_leftitems
105 106 107 108 109 110 |
# File 'lib/qa_server/configuration.rb', line 105 def return if .present? ||= QaServer::.new .() end |
#performance_tracker ⇒ Object
112 113 114 115 116 |
# File 'lib/qa_server/configuration.rb', line 112 def performance_tracker @performance_tracker ||= File.new('log/performance.csv', 'w').tap do |f| f.puts('action, http request, load graph, normalization, TOTAL, data size, authority') end end |