engineyard-serverside-adapter 1.5.35.pre.2 → 1.6.0.pre

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,13 +1,23 @@
1
1
  module EY
2
2
  module Serverside
3
3
  class Adapter
4
- class Arguments < Struct.new(:app, :config, :framework_env, :instances, :migrate, :ref, :repo, :stack, :verbose)
4
+ class Arguments < Struct.new(:app, :environment_name, :account_name, :config, :framework_env, :instances, :migrate, :ref, :repo, :stack, :verbose)
5
5
 
6
6
  def app=(app)
7
7
  enforce_nonempty!('app', app)
8
8
  super
9
9
  end
10
10
 
11
+ def environment_name=(env)
12
+ enforce_nonempty!('environment_name', env)
13
+ super
14
+ end
15
+
16
+ def account_name=(acc)
17
+ enforce_nonempty!('account_name', acc)
18
+ super
19
+ end
20
+
11
21
  def framework_env=(framework_env)
12
22
  enforce_nonempty!('framework_env', framework_env)
13
23
  super
@@ -3,15 +3,17 @@ module EY
3
3
  class Adapter
4
4
  class Deploy < Action
5
5
 
6
- option :app, :string, :required => true
7
- option :stack, :string, :required => true
8
- option :instances, :instances, :required => true
9
- option :config, :json
10
- option :verbose, :boolean
11
- option :framework_env, :string, :required => true
12
- option :ref, :string, :required => true
13
- option :repo, :string, :required => true
14
- option :migrate, :string
6
+ option :app, :string, :required => true
7
+ option :account_name, :string, :required => true
8
+ option :environment_name, :string, :required => true
9
+ option :stack, :string, :required => true
10
+ option :instances, :instances, :required => true
11
+ option :config, :json
12
+ option :verbose, :boolean
13
+ option :framework_env, :string, :required => true
14
+ option :ref, :string, :required => true
15
+ option :repo, :string, :required => true
16
+ option :migrate, :string
15
17
 
16
18
  private
17
19
 
@@ -3,9 +3,11 @@ module EY
3
3
  class Adapter
4
4
  class DisableMaintenancePage < Action
5
5
 
6
- option :app, :string, :required => true
7
- option :instances, :instances, :required => true
8
- option :verbose, :boolean
6
+ option :app, :string, :required => true
7
+ option :account_name, :string, :required => true
8
+ option :environment_name, :string, :required => true
9
+ option :instances, :instances, :required => true
10
+ option :verbose, :boolean
9
11
 
10
12
  private
11
13
 
@@ -3,9 +3,11 @@ module EY
3
3
  class Adapter
4
4
  class EnableMaintenancePage < Action
5
5
 
6
- option :app, :string, :required => true
7
- option :instances, :instances, :required => true
8
- option :verbose, :boolean
6
+ option :app, :string, :required => true
7
+ option :account_name, :string, :required => true
8
+ option :environment_name, :string, :required => true
9
+ option :instances, :instances, :required => true
10
+ option :verbose, :boolean
9
11
 
10
12
  private
11
13
 
@@ -3,11 +3,13 @@ module EY
3
3
  class Adapter
4
4
  class Integrate < Action
5
5
 
6
- option :app, :string, :required => true
7
- option :stack, :string, :required => true
8
- option :instances, :instances, :required => true
9
- option :framework_env, :string, :required => true
10
- option :verbose, :boolean
6
+ option :app, :string, :required => true
7
+ option :account_name, :string, :required => true
8
+ option :environment_name, :string, :required => true
9
+ option :stack, :string, :required => true
10
+ option :instances, :instances, :required => true
11
+ option :framework_env, :string, :required => true
12
+ option :verbose, :boolean
11
13
 
12
14
  private
13
15
 
@@ -3,10 +3,12 @@ module EY
3
3
  class Adapter
4
4
  class Restart < Action
5
5
 
6
- option :app, :string, :required => true
7
- option :instances, :instances, :required => true
8
- option :stack, :string, :required => true
9
- option :verbose, :boolean
6
+ option :app, :string, :required => true
7
+ option :account_name, :string, :required => true
8
+ option :environment_name, :string, :required => true
9
+ option :instances, :instances, :required => true
10
+ option :stack, :string, :required => true
11
+ option :verbose, :boolean
10
12
 
11
13
  private
12
14
 
@@ -3,12 +3,14 @@ module EY
3
3
  class Adapter
4
4
  class Rollback < Action
5
5
 
6
- option :app, :string, :required => true
7
- option :config, :json
8
- option :framework_env, :string, :required => true
9
- option :instances, :instances, :required => true
10
- option :stack, :string, :required => true
11
- option :verbose, :boolean
6
+ option :app, :string, :required => true
7
+ option :account_name, :string, :required => true
8
+ option :environment_name, :string, :required => true
9
+ option :config, :json
10
+ option :framework_env, :string, :required => true
11
+ option :instances, :instances, :required => true
12
+ option :stack, :string, :required => true
13
+ option :verbose, :boolean
12
14
 
13
15
  private
14
16
 
@@ -1,7 +1,7 @@
1
1
  module EY
2
2
  module Serverside
3
3
  class Adapter
4
- VERSION = "1.5.35.pre.2"
4
+ VERSION = "1.6.0.pre"
5
5
  end
6
6
  end
7
7
  end
@@ -14,7 +14,10 @@ module EY
14
14
  autoload :Rollback, 'engineyard-serverside-adapter/rollback'
15
15
  autoload :VERSION, 'engineyard-serverside-adapter/version'
16
16
 
17
- ENGINEYARD_SERVERSIDE_VERSION = ENV['ENGINEYARD_SERVERSIDE_VERSION'] || VERSION
17
+ # engineyard-serverside uses major.minor.patch; using a
18
+ # potentially-4-digit version lets us release fixes in the
19
+ # adapter while still keeping in version sync
20
+ ENGINEYARD_SERVERSIDE_VERSION = ENV['ENGINEYARD_SERVERSIDE_VERSION'] || VERSION.split('.')[0..2].join('.')
18
21
 
19
22
  def initialize(gem_bin_path = "")
20
23
  @gem_bin_path = Pathname.new(gem_bin_path)
data/spec/adapter_spec.rb CHANGED
@@ -3,12 +3,14 @@ require 'spec_helper'
3
3
  shared_examples_for "a serverside action" do
4
4
  before(:each) do
5
5
  @adapter = described_class.new do |args|
6
- args.app = 'app-from-adapter-new'
7
- args.instances = [{:hostname => 'localhost', :roles => %w[a b c]}]
8
- args.framework_env = 'production'
9
- args.ref = 'master'
10
- args.repo = 'git@github.com:engineyard/engineyard-serverside.git'
11
- args.stack = 'nginx_unicorn'
6
+ args.app = 'app-from-adapter-new'
7
+ args.environment_name = 'env-from-adapter-new'
8
+ args.account_name = 'acc-from-adapter-new'
9
+ args.instances = [{:hostname => 'localhost', :roles => %w[a b c]}]
10
+ args.framework_env = 'production'
11
+ args.ref = 'master'
12
+ args.repo = 'git@github.com:engineyard/engineyard-serverside.git'
13
+ args.stack = 'nginx_unicorn'
12
14
  args
13
15
  end
14
16
  end
@@ -54,12 +56,14 @@ shared_examples_for "a serverside action" do
54
56
  context "with a pathname specified" do
55
57
  it "begins both commands with the given path" do
56
58
  adapter = described_class.new("/usr/local/grin") do |args|
57
- args.app = 'app-from-adapter-new'
58
- args.instances = [{:hostname => 'localhost', :roles => %w[a b c]}]
59
- args.framework_env = 'production'
60
- args.ref = 'master'
61
- args.repo = 'git@github.com:engineyard/engineyard-serverside.git'
62
- args.stack = 'nginx_unicorn'
59
+ args.app = 'app-from-adapter-new'
60
+ args.environment_name = 'env-from-adapter-new'
61
+ args.account_name = 'acc-from-adapter-new'
62
+ args.instances = [{:hostname => 'localhost', :roles => %w[a b c]}]
63
+ args.framework_env = 'production'
64
+ args.ref = 'master'
65
+ args.repo = 'git@github.com:engineyard/engineyard-serverside.git'
66
+ args.stack = 'nginx_unicorn'
63
67
  args
64
68
  end
65
69
 
@@ -104,12 +108,14 @@ describe EY::Serverside::Adapter do
104
108
  context "mapping of methods to action classes" do
105
109
  before(:each) do
106
110
  @adapter = described_class.new do |args|
107
- args.app = 'app-from-adapter-new'
108
- args.instances = [{:hostname => 'localhost', :roles => %w[a b c]}]
109
- args.framework_env = 'production'
110
- args.ref = 'master'
111
- args.repo = 'git@github.com:engineyard/engineyard-serverside.git'
112
- args.stack = 'nginx_unicorn'
111
+ args.app = 'app-from-adapter-new'
112
+ args.environment_name = 'env-from-adapter-new'
113
+ args.account_name = 'acc-from-adapter-new'
114
+ args.instances = [{:hostname => 'localhost', :roles => %w[a b c]}]
115
+ args.framework_env = 'production'
116
+ args.ref = 'master'
117
+ args.repo = 'git@github.com:engineyard/engineyard-serverside.git'
118
+ args.stack = 'nginx_unicorn'
113
119
  args
114
120
  end
115
121
  end
data/spec/deploy_spec.rb CHANGED
@@ -4,6 +4,8 @@ describe EY::Serverside::Adapter::Deploy do
4
4
  it_should_behave_like "it installs engineyard-serverside"
5
5
 
6
6
  it_should_behave_like "it accepts app"
7
+ it_should_behave_like "it accepts environment_name"
8
+ it_should_behave_like "it accepts account_name"
7
9
  it_should_behave_like "it accepts framework_env"
8
10
  it_should_behave_like "it accepts instances"
9
11
  it_should_behave_like "it accepts migrate"
@@ -13,6 +15,8 @@ describe EY::Serverside::Adapter::Deploy do
13
15
  it_should_behave_like "it accepts verbose"
14
16
 
15
17
  it_should_require :app
18
+ it_should_require :environment_name
19
+ it_should_require :account_name
16
20
  it_should_require :instances
17
21
  it_should_require :framework_env
18
22
  it_should_require :ref
@@ -25,14 +29,16 @@ describe EY::Serverside::Adapter::Deploy do
25
29
  context "with valid arguments" do
26
30
  let(:command) do
27
31
  adapter = described_class.new do |arguments|
28
- arguments.app = "rackapp"
29
- arguments.framework_env = 'production'
30
- arguments.config = {'a' => 1}
31
- arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
32
- arguments.migrate = 'rake db:migrate'
33
- arguments.ref = 'master'
34
- arguments.repo = 'git@github.com:engineyard/engineyard-serverside.git'
35
- arguments.stack = "nginx_unicorn"
32
+ arguments.app = "rackapp"
33
+ arguments.environment_name = 'rackapp_production'
34
+ arguments.account_name = 'ey'
35
+ arguments.framework_env = 'production'
36
+ arguments.config = {'a' => 1}
37
+ arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
38
+ arguments.migrate = 'rake db:migrate'
39
+ arguments.ref = 'master'
40
+ arguments.repo = 'git@github.com:engineyard/engineyard-serverside.git'
41
+ arguments.stack = "nginx_unicorn"
36
42
  end
37
43
  last_command(adapter)
38
44
  end
@@ -42,7 +48,23 @@ describe EY::Serverside::Adapter::Deploy do
42
48
  end
43
49
 
44
50
  it "invokes exactly the right command" do
45
- command.should == "engineyard-serverside _#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_ deploy --app rackapp --config '{\"a\":1}' --framework-env production --instance-names localhost:chewie --instance-roles localhost:han,solo --instances localhost --migrate 'rake db:migrate' --ref master --repo git@github.com:engineyard/engineyard-serverside.git --stack nginx_unicorn"
51
+ command.should == [
52
+ "engineyard-serverside",
53
+ "_#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_",
54
+ "deploy",
55
+ "--account-name ey",
56
+ "--app rackapp",
57
+ "--config '{\"a\":1}'",
58
+ "--environment-name rackapp_production",
59
+ "--framework-env production",
60
+ "--instance-names localhost:chewie",
61
+ "--instance-roles localhost:han,solo",
62
+ "--instances localhost",
63
+ "--migrate 'rake db:migrate'",
64
+ "--ref master",
65
+ "--repo git@github.com:engineyard/engineyard-serverside.git",
66
+ "--stack nginx_unicorn",
67
+ ].join(' ')
46
68
  end
47
69
  end
48
70
  end
@@ -4,23 +4,39 @@ describe EY::Serverside::Adapter::DisableMaintenancePage do
4
4
  it_should_behave_like "it installs engineyard-serverside"
5
5
 
6
6
  it_should_behave_like "it accepts app"
7
+ it_should_behave_like "it accepts environment_name"
8
+ it_should_behave_like "it accepts account_name"
7
9
  it_should_behave_like "it accepts instances"
8
10
  it_should_behave_like "it accepts verbose"
9
11
 
10
12
  it_should_require :app
13
+ it_should_require :environment_name
14
+ it_should_require :account_name
11
15
  it_should_require :instances
12
16
 
13
17
  context "with valid arguments" do
14
18
  let(:command) do
15
19
  adapter = described_class.new do |arguments|
16
- arguments.app = "rackapp"
17
- arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
20
+ arguments.app = "rackapp"
21
+ arguments.environment_name = "rackapp_production"
22
+ arguments.account_name = "ey"
23
+ arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
18
24
  end
19
25
  last_command(adapter)
20
26
  end
21
27
 
22
28
  it "invokes exactly the right command" do
23
- command.should == "engineyard-serverside _#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_ deploy disable_maintenance_page --app rackapp --instance-names localhost:chewie --instance-roles localhost:han,solo --instances localhost"
29
+ command.should == [
30
+ "engineyard-serverside",
31
+ "_#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_",
32
+ "deploy disable_maintenance_page",
33
+ "--account-name ey",
34
+ "--app rackapp",
35
+ "--environment-name rackapp_production",
36
+ "--instance-names localhost:chewie",
37
+ "--instance-roles localhost:han,solo",
38
+ "--instances localhost",
39
+ ].join(' ')
24
40
  end
25
41
  end
26
42
  end
@@ -4,24 +4,40 @@ describe EY::Serverside::Adapter::EnableMaintenancePage do
4
4
  it_should_behave_like "it installs engineyard-serverside"
5
5
 
6
6
  it_should_behave_like "it accepts app"
7
+ it_should_behave_like "it accepts environment_name"
8
+ it_should_behave_like "it accepts account_name"
7
9
  it_should_behave_like "it accepts instances"
8
10
  it_should_behave_like "it accepts verbose"
9
11
 
10
12
  it_should_require :app
13
+ it_should_require :environment_name
14
+ it_should_require :account_name
11
15
  it_should_require :instances
12
16
 
13
17
  context "with valid arguments" do
14
18
 
15
19
  let(:command) do
16
20
  adapter = described_class.new do |arguments|
17
- arguments.app = "rackapp"
18
- arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
21
+ arguments.app = "rackapp"
22
+ arguments.environment_name = "rackapp_production"
23
+ arguments.account_name = "ey"
24
+ arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
19
25
  end
20
26
  last_command(adapter)
21
27
  end
22
28
 
23
29
  it "invokes exactly the right command" do
24
- command.should == "engineyard-serverside _#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_ deploy enable_maintenance_page --app rackapp --instance-names localhost:chewie --instance-roles localhost:han,solo --instances localhost"
30
+ command.should == [
31
+ "engineyard-serverside",
32
+ "_#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_",
33
+ "deploy enable_maintenance_page",
34
+ "--account-name ey",
35
+ "--app rackapp",
36
+ "--environment-name rackapp_production",
37
+ "--instance-names localhost:chewie",
38
+ "--instance-roles localhost:han,solo",
39
+ "--instances localhost",
40
+ ].join(' ')
25
41
  end
26
42
  end
27
43
 
@@ -4,12 +4,16 @@ describe EY::Serverside::Adapter::Integrate do
4
4
  it_should_behave_like "it installs engineyard-serverside"
5
5
 
6
6
  it_should_behave_like "it accepts app"
7
+ it_should_behave_like "it accepts environment_name"
8
+ it_should_behave_like "it accepts account_name"
7
9
  it_should_behave_like "it accepts framework_env"
8
10
  it_should_behave_like "it accepts instances"
9
11
  it_should_behave_like "it accepts stack"
10
12
  it_should_behave_like "it accepts verbose"
11
13
 
12
14
  it_should_require :app
15
+ it_should_require :environment_name
16
+ it_should_require :account_name
13
17
  it_should_require :stack
14
18
  it_should_require :instances
15
19
  it_should_require :framework_env
@@ -17,16 +21,30 @@ describe EY::Serverside::Adapter::Integrate do
17
21
  context "with valid arguments" do
18
22
  let(:command) do
19
23
  adapter = described_class.new do |arguments|
20
- arguments.app = "rackapp"
21
- arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
22
- arguments.stack = "nginx_unicorn"
23
- arguments.framework_env = "production"
24
+ arguments.app = "rackapp"
25
+ arguments.environment_name = "rackapp_production"
26
+ arguments.account_name = "ey"
27
+ arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
28
+ arguments.stack = "nginx_unicorn"
29
+ arguments.framework_env = "production"
24
30
  end
25
31
  last_command(adapter)
26
32
  end
27
33
 
28
34
  it "invokes exactly the right command" do
29
- command.should == "engineyard-serverside _#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_ integrate --app rackapp --framework-env production --instance-names localhost:chewie --instance-roles localhost:han,solo --instances localhost --stack nginx_unicorn"
35
+ command.should == [
36
+ "engineyard-serverside",
37
+ "_#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_",
38
+ "integrate",
39
+ "--account-name ey",
40
+ "--app rackapp",
41
+ "--environment-name rackapp_production",
42
+ "--framework-env production",
43
+ "--instance-names localhost:chewie",
44
+ "--instance-roles localhost:han,solo",
45
+ "--instances localhost",
46
+ "--stack nginx_unicorn",
47
+ ].join(' ')
30
48
  end
31
49
  end
32
50
  end
data/spec/restart_spec.rb CHANGED
@@ -4,26 +4,43 @@ describe EY::Serverside::Adapter::Restart do
4
4
  it_should_behave_like "it installs engineyard-serverside"
5
5
 
6
6
  it_should_behave_like "it accepts app"
7
+ it_should_behave_like "it accepts environment_name"
8
+ it_should_behave_like "it accepts account_name"
7
9
  it_should_behave_like "it accepts instances"
8
10
  it_should_behave_like "it accepts stack"
9
11
  it_should_behave_like "it accepts verbose"
10
12
 
11
13
  it_should_require :app
14
+ it_should_require :environment_name
15
+ it_should_require :account_name
12
16
  it_should_require :instances
13
17
  it_should_require :stack
14
18
 
15
19
  context "with valid arguments" do
16
20
  let(:command) do
17
21
  adapter = described_class.new do |arguments|
18
- arguments.app = "rackapp"
19
- arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
20
- arguments.stack = "nginx_unicorn"
22
+ arguments.app = "rackapp"
23
+ arguments.environment_name = "rackapp_production"
24
+ arguments.account_name = "ey"
25
+ arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
26
+ arguments.stack = "nginx_unicorn"
21
27
  end
22
28
  last_command(adapter)
23
29
  end
24
30
 
25
31
  it "invokes exactly the right command" do
26
- command.should == "engineyard-serverside _#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_ restart --app rackapp --instance-names localhost:chewie --instance-roles localhost:han,solo --instances localhost --stack nginx_unicorn"
32
+ command.should == [
33
+ "engineyard-serverside",
34
+ "_#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_",
35
+ "restart",
36
+ "--account-name ey",
37
+ "--app rackapp",
38
+ "--environment-name rackapp_production",
39
+ "--instance-names localhost:chewie",
40
+ "--instance-roles localhost:han,solo",
41
+ "--instances localhost",
42
+ "--stack nginx_unicorn",
43
+ ].join(' ')
27
44
  end
28
45
  end
29
46
  end
@@ -4,12 +4,16 @@ describe EY::Serverside::Adapter::Rollback do
4
4
  it_should_behave_like "it installs engineyard-serverside"
5
5
 
6
6
  it_should_behave_like "it accepts app"
7
+ it_should_behave_like "it accepts environment_name"
8
+ it_should_behave_like "it accepts account_name"
7
9
  it_should_behave_like "it accepts framework_env"
8
10
  it_should_behave_like "it accepts instances"
9
11
  it_should_behave_like "it accepts stack"
10
12
  it_should_behave_like "it accepts verbose"
11
13
 
12
14
  it_should_require :app
15
+ it_should_require :environment_name
16
+ it_should_require :account_name
13
17
  it_should_require :framework_env
14
18
  it_should_require :instances
15
19
  it_should_require :stack
@@ -17,11 +21,13 @@ describe EY::Serverside::Adapter::Rollback do
17
21
  context "with valid arguments" do
18
22
  let(:command) do
19
23
  adapter = described_class.new do |arguments|
20
- arguments.app = "rackapp"
21
- arguments.framework_env = 'production'
22
- arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
23
- arguments.stack = "nginx_unicorn"
24
- arguments.config = {'a' => 1}
24
+ arguments.app = "rackapp"
25
+ arguments.environment_name = "rackapp_production"
26
+ arguments.account_name = "ey"
27
+ arguments.framework_env = 'production'
28
+ arguments.instances = [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}]
29
+ arguments.stack = "nginx_unicorn"
30
+ arguments.config = {'a' => 1}
25
31
  end
26
32
  last_command(adapter)
27
33
  end
@@ -31,7 +37,20 @@ describe EY::Serverside::Adapter::Rollback do
31
37
  end
32
38
 
33
39
  it "invokes exactly the right command" do
34
- command.should == "engineyard-serverside _#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_ deploy rollback --app rackapp --config '{\"a\":1}' --framework-env production --instance-names localhost:chewie --instance-roles localhost:han,solo --instances localhost --stack nginx_unicorn"
40
+ command.should == [
41
+ "engineyard-serverside",
42
+ "_#{EY::Serverside::Adapter::ENGINEYARD_SERVERSIDE_VERSION}_",
43
+ "deploy rollback",
44
+ "--account-name ey",
45
+ "--app rackapp",
46
+ "--config '{\"a\":1}'",
47
+ "--environment-name rackapp_production",
48
+ "--framework-env production",
49
+ "--instance-names localhost:chewie",
50
+ "--instance-roles localhost:han,solo",
51
+ "--instances localhost",
52
+ "--stack nginx_unicorn",
53
+ ].join(' ')
35
54
  end
36
55
  end
37
56
  end
data/spec/spec_helper.rb CHANGED
@@ -7,12 +7,14 @@ require 'pp'
7
7
  module ArgumentsHelpers
8
8
  def valid_options
9
9
  {
10
- :app => 'rackapp',
11
- :framework_env => 'production',
12
- :instances => [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}],
13
- :ref => 'master',
14
- :repo => 'git@github.com:engineyard/engineyard-serverside.git',
15
- :stack => 'nginx_unicorn',
10
+ :app => 'rackapp',
11
+ :environment_name => 'rackapp_production',
12
+ :account_name => 'ey',
13
+ :framework_env => 'production',
14
+ :instances => [{:hostname => 'localhost', :roles => %w[han solo], :name => 'chewie'}],
15
+ :ref => 'master',
16
+ :repo => 'git@github.com:engineyard/engineyard-serverside.git',
17
+ :stack => 'nginx_unicorn',
16
18
  }
17
19
  end
18
20
 
@@ -103,12 +105,14 @@ RSpec.configure do |config|
103
105
  end
104
106
 
105
107
  {
106
- :app => '--app',
107
- :stack => '--stack',
108
- :framework_env => '--framework-env',
109
- :ref => '--ref',
110
- :repo => '--repo',
111
- :migrate => '--migrate',
108
+ :app => '--app',
109
+ :environment_name => '--environment-name',
110
+ :account_name => '--account-name',
111
+ :stack => '--stack',
112
+ :framework_env => '--framework-env',
113
+ :ref => '--ref',
114
+ :repo => '--repo',
115
+ :migrate => '--migrate',
112
116
  }.each do |arg, switch|
113
117
  shared_examples_for "it accepts #{arg}" do
114
118
  it "puts the #{switch} arg in the command line" do
metadata CHANGED
@@ -1,8 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: engineyard-serverside-adapter
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.35.pre.2
5
- prerelease: 7
4
+ version: 1.6.0.pre
5
+ prerelease: 6
6
6
  platform: ruby
7
7
  authors:
8
8
  - Martin Emde
@@ -10,11 +10,11 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2012-03-23 00:00:00.000000000 Z
13
+ date: 2012-02-25 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: escape
17
- requirement: !ruby/object:Gem::Requirement
17
+ requirement: &70231298925880 !ruby/object:Gem::Requirement
18
18
  none: false
19
19
  requirements:
20
20
  - - ~>
@@ -22,15 +22,10 @@ dependencies:
22
22
  version: 0.0.4
23
23
  type: :runtime
24
24
  prerelease: false
25
- version_requirements: !ruby/object:Gem::Requirement
26
- none: false
27
- requirements:
28
- - - ~>
29
- - !ruby/object:Gem::Version
30
- version: 0.0.4
25
+ version_requirements: *70231298925880
31
26
  - !ruby/object:Gem::Dependency
32
27
  name: json_pure
33
- requirement: !ruby/object:Gem::Requirement
28
+ requirement: &70231298925360 !ruby/object:Gem::Requirement
34
29
  none: false
35
30
  requirements:
36
31
  - - ! '>='
@@ -38,15 +33,10 @@ dependencies:
38
33
  version: '0'
39
34
  type: :runtime
40
35
  prerelease: false
41
- version_requirements: !ruby/object:Gem::Requirement
42
- none: false
43
- requirements:
44
- - - ! '>='
45
- - !ruby/object:Gem::Version
46
- version: '0'
36
+ version_requirements: *70231298925360
47
37
  - !ruby/object:Gem::Dependency
48
38
  name: rspec
49
- requirement: !ruby/object:Gem::Requirement
39
+ requirement: &70231298940100 !ruby/object:Gem::Requirement
50
40
  none: false
51
41
  requirements:
52
42
  - - ~>
@@ -54,15 +44,10 @@ dependencies:
54
44
  version: '2.0'
55
45
  type: :development
56
46
  prerelease: false
57
- version_requirements: !ruby/object:Gem::Requirement
58
- none: false
59
- requirements:
60
- - - ~>
61
- - !ruby/object:Gem::Version
62
- version: '2.0'
47
+ version_requirements: *70231298940100
63
48
  - !ruby/object:Gem::Dependency
64
49
  name: rake
65
- requirement: !ruby/object:Gem::Requirement
50
+ requirement: &70231298939520 !ruby/object:Gem::Requirement
66
51
  none: false
67
52
  requirements:
68
53
  - - ! '>='
@@ -70,12 +55,7 @@ dependencies:
70
55
  version: '0'
71
56
  type: :development
72
57
  prerelease: false
73
- version_requirements: !ruby/object:Gem::Requirement
74
- none: false
75
- requirements:
76
- - - ! '>='
77
- - !ruby/object:Gem::Version
78
- version: '0'
58
+ version_requirements: *70231298939520
79
59
  description: A separate adapter for speaking the CLI language of the engineyard-serverside
80
60
  gem.
81
61
  email:
@@ -131,7 +111,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
131
111
  version: 1.3.6
132
112
  requirements: []
133
113
  rubyforge_project: engineyard-serverside-adapter
134
- rubygems_version: 1.8.19
114
+ rubygems_version: 1.8.15
135
115
  signing_key:
136
116
  specification_version: 3
137
117
  summary: Adapter for speaking to engineyard-serverside