Class: DeepThought::CIService::CIService
- Inherits:
-
Object
- Object
- DeepThought::CIService::CIService
- Defined in:
- lib/deep_thought/ci_service/ci_service.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#endpoint ⇒ Object
Returns the value of attribute endpoint.
-
#password ⇒ Object
Returns the value of attribute password.
-
#username ⇒ Object
Returns the value of attribute username.
Instance Method Summary collapse
-
#initialize ⇒ CIService
constructor
A new instance of CIService.
- #is_branch_green?(app, branch, hash) ⇒ Boolean
- #setup?(settings) ⇒ Boolean
Constructor Details
#initialize ⇒ CIService
Returns a new instance of CIService.
6 7 8 9 10 |
# File 'lib/deep_thought/ci_service/ci_service.rb', line 6 def initialize if self.class.name == 'DeepThought::CIService::CIService' raise "#{self.class.name} is abstract, you cannot instantiate it directly." end end |
Instance Attribute Details
#endpoint ⇒ Object
Returns the value of attribute endpoint.
4 5 6 |
# File 'lib/deep_thought/ci_service/ci_service.rb', line 4 def endpoint @endpoint end |
#password ⇒ Object
Returns the value of attribute password.
4 5 6 |
# File 'lib/deep_thought/ci_service/ci_service.rb', line 4 def password @password end |
#username ⇒ Object
Returns the value of attribute username.
4 5 6 |
# File 'lib/deep_thought/ci_service/ci_service.rb', line 4 def username @username end |
Instance Method Details
#is_branch_green?(app, branch, hash) ⇒ Boolean
20 21 22 |
# File 'lib/deep_thought/ci_service/ci_service.rb', line 20 def is_branch_green?(app, branch, hash) true end |
#setup?(settings) ⇒ Boolean
12 13 14 15 16 17 18 |
# File 'lib/deep_thought/ci_service/ci_service.rb', line 12 def setup?(settings) @endpoint = settings['CI_SERVICE_ENDPOINT'] @username = settings['CI_SERVICE_USERNAME'] @password = settings['CI_SERVICE_PASSWORD'] true end |