Class: GitMaintain::RDMACoreCI
Constant Summary collapse
- AZURE_MIN_VERSION =
18
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
Returns a new instance of RDMACoreCI.
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 |
# File 'lib/addons/RDMACore.rb', line 135 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
163 164 165 166 |
# File 'lib/addons/RDMACore.rb', line 163 def emptyCache() @travis.emptyCache() @azure.emptyCache() end |