Class: Vx::Message::PerformBuild

Inherits:
Object
  • Object
show all
Includes:
Beefcake::Message
Defined in:
lib/vx/message/testing.rb,
lib/vx/message/messages.pb.rb

Class Method Summary collapse

Class Method Details

.test_attributes(options = {}) ⇒ Object



126
127
128
129
130
131
132
133
134
135
136
137
138
# File 'lib/vx/message/testing.rb', line 126

def test_attributes(options = {})
  key = File.read File.expand_path("../../../../fixtures/insecure_private_key", __FILE__)
  travis = File.read File.expand_path("../../../../fixtures/travis.yml", __FILE__)
  options.merge({
    id:         options[:id]         || 1,
    name:       options[:name]       || 'evrone/test-repo',
    src:        options[:src]        || "[email protected]:dima-exe/ci-worker-test-repo.git",
    sha:        options[:sha]        || "b665f90239563c030f1b280a434b3d84daeda1bd",
    deploy_key: options[:deploy_key] || key,
    travis:     options[:travis]     || travis,
    branch:     options[:branch]     || "master"
  })
end

.test_message(options = {}) ⇒ Object



140
141
142
# File 'lib/vx/message/testing.rb', line 140

def test_message(options = {})
  new test_attributes(options)
end