Class: SiteHealth::GooglePageSpeed
- Defined in:
- lib/site_health/checkers/google_page_speed.rb
Constant Summary collapse
- Pagespeedonline =
Google::Apis::PagespeedonlineV2
- PagespeedService =
Pagespeedonline::PagespeedonlineService
Constants inherited from Checker
Instance Attribute Summary collapse
-
#service ⇒ Object
readonly
Returns the value of attribute service.
Attributes inherited from Checker
#config, #data, #issues, #logger, #page
Instance Method Summary collapse
-
#initialize(*args, **keyword_args) ⇒ GooglePageSpeed
constructor
A new instance of GooglePageSpeed.
Methods inherited from Checker
#add_data, #add_issue, #add_issue_type, #call, issue_types, #issue_types, name, #name, #should_check?, #to_h, #types, types, #url
Constructor Details
#initialize(*args, **keyword_args) ⇒ GooglePageSpeed
Returns a new instance of GooglePageSpeed.
18 19 20 21 22 23 24 25 26 |
# File 'lib/site_health/checkers/google_page_speed.rb', line 18 def initialize(*args, **keyword_args) super(*args, **keyword_args) @service = PagespeedService.new @service.key = config.google_page_speed_api_key Google::Apis.logger = logger Google::Apis.logger.level = logger.level if logger.level end |
Instance Attribute Details
#service ⇒ Object (readonly)
Returns the value of attribute service.
16 17 18 |
# File 'lib/site_health/checkers/google_page_speed.rb', line 16 def service @service end |