Class: GitMaintain::RDMACoreCI
Constant Summary collapse
- AZURE_MIN_VERSION =
25
Instance Method Summary collapse
- #emptyCache ⇒ Object
-
#initialize(repo) ⇒ RDMACoreCI
constructor
A new instance of RDMACoreCI.
Methods inherited from CI
#checkStableState, #checkValidState, #getStableLog, #getStableState, #getStableTS, #getValidLog, #getValidState, #getValidTS, #isErrored, load
Constructor Details
#initialize(repo) ⇒ RDMACoreCI
126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 |
# File 'lib/addons/RDMACore.rb', line 126 def initialize(repo) super(repo) @travis = GitMaintain::TravisCI.new(repo) @azure = GitMaintain::AzureCI.new(repo, 'ucfconsort', 'ucfconsort') # Auto generate all CI required methods # Wicked ruby tricker to find all the public methods of CI but not of inherited classes # to dynamically define these method in the object being created (GitMaintain::CI.new(repo).public_methods() - Object.new.public_methods()).each(){|method| # Skip specific emptyCache method next if method == :emptyCache self.define_singleton_method(method) { |br, *args| if br.version =~ /([0-9]+)/ major=$1.to_i elsif br.version == "master" major=99999 else raise("Unable to monitor branch #{br} on a CI") end if major < AZURE_MIN_VERSION @travis.send(method, br, *args) else @azure.send(method, br, *args) end } } end |
Instance Method Details
#emptyCache ⇒ Object
154 155 156 157 |
# File 'lib/addons/RDMACore.rb', line 154 def emptyCache() @travis.emptyCache() @azure.emptyCache() end |