vlad 2.0.0 → 2.1.0
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.
- data/.autotest +2 -1
- data/History.txt +29 -0
- data/Manifest.txt +1 -3
- data/Rakefile +5 -13
- data/doco/faq.txt +6 -1
- data/lib/vlad/core.rb +8 -26
- data/lib/vlad/rails.rb +34 -0
- data/lib/vlad.rb +7 -20
- data/test/test_vlad.rb +51 -52
- data/test/test_vlad_subversion.rb +1 -2
- data.tar.gz.sig +0 -0
- metadata +118 -23
- metadata.gz.sig +0 -0
- data/lib/rake_remote_task.rb +0 -589
- data/lib/vlad_test_case.rb +0 -72
- data/test/test_rake_remote_task.rb +0 -261
data/.autotest
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
# -*- ruby -*-
|
2
2
|
|
3
3
|
require 'autotest/restart'
|
4
|
+
require 'autotest/rcov'
|
4
5
|
|
5
6
|
Autotest.add_hook :initialize do |at|
|
6
7
|
at.testlib = "minitest/autorun"
|
7
8
|
# at.extra_files << "../some/external/dependency.rb"
|
8
9
|
#
|
9
|
-
|
10
|
+
at.libs << ":../../rake-remote_task/dev/lib"
|
10
11
|
#
|
11
12
|
# at.add_exception 'vendor'
|
12
13
|
#
|
data/History.txt
CHANGED
@@ -1,3 +1,32 @@
|
|
1
|
+
=== 2.1.0 / 2010-07-15
|
2
|
+
|
3
|
+
* 1 major enhancement:
|
4
|
+
|
5
|
+
* Split out rake_remote_task.rb and vlad_test_case.rb (in rake-remote_task gem).
|
6
|
+
|
7
|
+
* 4 minor enhancements:
|
8
|
+
|
9
|
+
* Added :type config option, defaulting to rails
|
10
|
+
* Moved VladTestCase to Rake::TestCase (in rake-remote_task gem).
|
11
|
+
* Moved all Vlad exceptions to Rake (in rake-remote_task gem).
|
12
|
+
* Refactored rails specific values out of core. (raggi)
|
13
|
+
|
14
|
+
* 2 bug fixes:
|
15
|
+
|
16
|
+
* Clarified Rake.clear_tasks in faq
|
17
|
+
* Fixed output from vlad:invoke (pnc)
|
18
|
+
|
19
|
+
=== 2.0.0 / 2009-08-18
|
20
|
+
|
21
|
+
* 1 major enhancement:
|
22
|
+
|
23
|
+
* Removed all extra modules that we don't support in core anymore.
|
24
|
+
|
25
|
+
* 2 minor enhancements:
|
26
|
+
|
27
|
+
* Added test to show that false is a valid variable value.
|
28
|
+
* Moved vlad_test_case from test to lib to support 3rd party vlad modules.
|
29
|
+
|
1
30
|
=== 1.4.0 / 2009-06-23
|
2
31
|
|
3
32
|
* 1 major enhancement:
|
data/Manifest.txt
CHANGED
@@ -11,15 +11,13 @@ doco/getting_started.txt
|
|
11
11
|
doco/migration.txt
|
12
12
|
doco/perforce.txt
|
13
13
|
doco/variables.txt
|
14
|
-
lib/rake_remote_task.rb
|
15
14
|
lib/vlad.rb
|
16
15
|
lib/vlad/apache.rb
|
17
16
|
lib/vlad/core.rb
|
18
17
|
lib/vlad/maintenance.rb
|
19
18
|
lib/vlad/passenger.rb
|
19
|
+
lib/vlad/rails.rb
|
20
20
|
lib/vlad/subversion.rb
|
21
|
-
lib/vlad_test_case.rb
|
22
|
-
test/test_rake_remote_task.rb
|
23
21
|
test/test_vlad.rb
|
24
22
|
test/test_vlad_subversion.rb
|
25
23
|
vladdemo.sh
|
data/Rakefile
CHANGED
@@ -5,6 +5,8 @@ require 'hoe'
|
|
5
5
|
|
6
6
|
Hoe.plugin :seattlerb
|
7
7
|
|
8
|
+
Hoe.add_include_dirs "../../rake-remote_task/dev/lib"
|
9
|
+
|
8
10
|
Hoe.spec 'vlad' do
|
9
11
|
self.rubyforge_name = 'hitsquad'
|
10
12
|
|
@@ -13,6 +15,7 @@ Hoe.spec 'vlad' do
|
|
13
15
|
developer 'Wilson Bilkovich', 'wilson@supremetyrant.com'
|
14
16
|
|
15
17
|
extra_deps << ['rake', '~> 0.8.0']
|
18
|
+
extra_deps << ['rake-remote_task', '~> 2.0']
|
16
19
|
extra_deps << ['open4', '~> 0.9.0']
|
17
20
|
|
18
21
|
# TODO: remove 1.9
|
@@ -21,6 +24,8 @@ end
|
|
21
24
|
|
22
25
|
desc "quick little hack to see what the state of the nation looks like"
|
23
26
|
task :debug do
|
27
|
+
$: << 'lib'
|
28
|
+
require 'vlad'
|
24
29
|
Vlad.load :config => "lib/vlad/subversion.rb"
|
25
30
|
set :repository, "repository path"
|
26
31
|
set :deploy_to, "deploy path"
|
@@ -29,17 +34,4 @@ task :debug do
|
|
29
34
|
Rake::Task['vlad:debug'].invoke
|
30
35
|
end
|
31
36
|
|
32
|
-
task :mana_from_heaven do
|
33
|
-
# vlad = vlad + rake + open4
|
34
|
-
# rake sans-contrib = 2035.98356718206
|
35
|
-
vlad = `flog -s lib`.to_f + 2350.30744806517 + 502.363818023761
|
36
|
-
cap = 11480.3919695285
|
37
|
-
ratio = cap / vlad
|
38
|
-
target = cap / Math::PI
|
39
|
-
|
40
|
-
puts "%14.8f = %s" % [vlad, "vlad"]
|
41
|
-
puts "%14.8f = %s" % [ratio, "ratio"]
|
42
|
-
puts "%14.8f = %s" % [target - vlad, "needed delta"]
|
43
|
-
end
|
44
|
-
|
45
37
|
# vim: syntax=ruby
|
data/doco/faq.txt
CHANGED
@@ -54,8 +54,13 @@ To prepend on a task, add a dependency:
|
|
54
54
|
=== Q: How can I replace a rake task instead of just adding to it?
|
55
55
|
=== A: Use Rake.clear_tasks str_or_regexp
|
56
56
|
|
57
|
+
NOTE: Rake.clear_tasks was moved to Hoe so it could be used more generally.
|
58
|
+
|
59
|
+
require 'hoe/rake'
|
60
|
+
|
57
61
|
namespace :vlad do
|
58
|
-
# Clear existing update task so that we can redefine instead of
|
62
|
+
# Clear existing update task so that we can redefine instead of
|
63
|
+
# adding to it.
|
59
64
|
Rake.clear_tasks('vlad:update')
|
60
65
|
|
61
66
|
remote_task :update, :roles => :app do
|
data/lib/vlad/core.rb
CHANGED
@@ -40,7 +40,7 @@ namespace :vlad do
|
|
40
40
|
|
41
41
|
remote_task :setup_app, :roles => :app do
|
42
42
|
dirs = [deploy_to, releases_path, scm_path, shared_path]
|
43
|
-
dirs +=
|
43
|
+
dirs += shared_paths.keys.map { |d| File.join(shared_path, d) }
|
44
44
|
run "umask #{umask} && mkdir -p #{dirs.join(' ')}"
|
45
45
|
end
|
46
46
|
|
@@ -56,8 +56,8 @@ namespace :vlad do
|
|
56
56
|
"#{source.checkout revision, scm_path}",
|
57
57
|
"#{source.export revision, release_path}",
|
58
58
|
"chmod -R g+w #{latest_release}",
|
59
|
-
"rm -rf #{
|
60
|
-
"mkdir -p #{
|
59
|
+
"rm -rf #{shared_paths.values.map { |p| File.join(latest_release, p) }.join(' ')}",
|
60
|
+
"mkdir -p #{mkdirs.map { |d| File.join(latest_release, d) }.join(' ')}"
|
61
61
|
].join(" && ")
|
62
62
|
Rake::Task['vlad:update_symlinks'].invoke
|
63
63
|
|
@@ -76,28 +76,10 @@ namespace :vlad do
|
|
76
76
|
desc "Updates the symlinks for shared paths".cleanup
|
77
77
|
|
78
78
|
remote_task :update_symlinks, :roles => :app do
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
desc "Run the migrate rake task for the the app. By default this is run in
|
85
|
-
the latest app directory. You can run migrations for the current app
|
86
|
-
directory by setting :migrate_target to :current. Additional environment
|
87
|
-
variables can be passed to rake via the migrate_env variable.".cleanup
|
88
|
-
|
89
|
-
# No application files are on the DB machine, also migrations should only be
|
90
|
-
# run once.
|
91
|
-
remote_task :migrate, :roles => :app do
|
92
|
-
break unless target_host == Rake::RemoteTask.hosts_for(:app).first
|
93
|
-
|
94
|
-
directory = case migrate_target.to_sym
|
95
|
-
when :current then current_path
|
96
|
-
when :latest then current_release
|
97
|
-
else raise ArgumentError, "unknown migration target #{migrate_target.inspect}"
|
98
|
-
end
|
99
|
-
|
100
|
-
run "cd #{directory}; #{rake_cmd} RAILS_ENV=#{rails_env} db:migrate #{migrate_args}"
|
79
|
+
ops = shared_paths.map do |sp, rp|
|
80
|
+
"ln -s #{shared_path}/#{sp} #{latest_release}/#{rp}"
|
81
|
+
end
|
82
|
+
run ops.join(' && ')
|
101
83
|
end
|
102
84
|
|
103
85
|
desc "Invoke a single command on every remote server. This is useful for
|
@@ -112,7 +94,7 @@ namespace :vlad do
|
|
112
94
|
remote_task :invoke do
|
113
95
|
command = ENV["COMMAND"]
|
114
96
|
abort "Please specify a command to execute on the remote servers (via the COMMAND environment variable)" unless command
|
115
|
-
|
97
|
+
run(command)
|
116
98
|
end
|
117
99
|
|
118
100
|
desc "Copy arbitrary files to the currently deployed version using
|
data/lib/vlad/rails.rb
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
namespace :vlad do
|
2
|
+
set :rails_env, "production"
|
3
|
+
set :migrate_args, ""
|
4
|
+
set :migrate_target, :latest
|
5
|
+
set :mkdirs, %w(tmp db)
|
6
|
+
set :shared_paths, {
|
7
|
+
'log' => 'log',
|
8
|
+
'system' => 'public/system',
|
9
|
+
'pids' => 'tmp/pids',
|
10
|
+
}
|
11
|
+
|
12
|
+
desc "Run the migrate rake task for the the app. By default this is run in
|
13
|
+
the latest app directory. You can run migrations for the current app
|
14
|
+
directory by setting :migrate_target to :current. Additional environment
|
15
|
+
variables can be passed to rake via the migrate_env variable.".cleanup
|
16
|
+
|
17
|
+
# No application files are on the DB machine, also migrations should only be
|
18
|
+
# run once.
|
19
|
+
remote_task :migrate, :roles => :app do
|
20
|
+
break unless target_host == Rake::RemoteTask.hosts_for(:app).first
|
21
|
+
|
22
|
+
directory = case migrate_target.to_sym
|
23
|
+
when :current then current_path
|
24
|
+
when :latest then current_release
|
25
|
+
else
|
26
|
+
raise(ArgumentError,
|
27
|
+
"unknown migration target #{migrate_target.inspect}")
|
28
|
+
end
|
29
|
+
|
30
|
+
run ["cd #{directory}",
|
31
|
+
"#{rake_cmd} RAILS_ENV=#{rails_env} db:migrate #{migrate_args}"
|
32
|
+
].join(" ")
|
33
|
+
end
|
34
|
+
end
|
data/lib/vlad.rb
CHANGED
@@ -1,11 +1,12 @@
|
|
1
1
|
require 'rubygems'
|
2
2
|
require 'thread'
|
3
|
-
require '
|
3
|
+
require 'rake/remote_task'
|
4
4
|
|
5
5
|
$TESTING ||= false
|
6
6
|
|
7
7
|
##
|
8
|
-
# Vlad the Deployer - Pragmatic application deployment automation,
|
8
|
+
# Vlad the Deployer - Pragmatic application deployment automation,
|
9
|
+
# without mercy.
|
9
10
|
#
|
10
11
|
# Please read doco/getting_started.txt or http://rubyhitsquad.com/
|
11
12
|
#
|
@@ -20,23 +21,7 @@ module Vlad
|
|
20
21
|
|
21
22
|
##
|
22
23
|
# This is the version of Vlad you are running.
|
23
|
-
VERSION = '2.
|
24
|
-
|
25
|
-
##
|
26
|
-
# Base error class for all Vlad errors.
|
27
|
-
class Error < RuntimeError; end
|
28
|
-
|
29
|
-
##
|
30
|
-
# Raised when you have incorrectly configured Vlad.
|
31
|
-
class ConfigurationError < Error; end
|
32
|
-
|
33
|
-
##
|
34
|
-
# Raised when a remote command fails.
|
35
|
-
class CommandFailedError < Error; end
|
36
|
-
|
37
|
-
##
|
38
|
-
# Raised when an environment variable hasn't been set.
|
39
|
-
class FetchError < Error; end
|
24
|
+
VERSION = '2.1.0'
|
40
25
|
|
41
26
|
##
|
42
27
|
# Loads tasks file +tasks_file+ and various recipe styles as a hash
|
@@ -56,13 +41,15 @@ module Vlad
|
|
56
41
|
# fit for you. All it does is a fancy-pants require. Require
|
57
42
|
# whatever files you need as you see fit straight from your
|
58
43
|
# Rakefile. YAY for simple and clean!
|
44
|
+
|
59
45
|
def self.load options = {}
|
60
46
|
options = {:config => options} if String === options
|
61
|
-
order = [:core, :app, :config, :scm, :web]
|
47
|
+
order = [:core, :type, :app, :config, :scm, :web]
|
62
48
|
order += options.keys - order
|
63
49
|
|
64
50
|
recipes = {
|
65
51
|
:app => :passenger,
|
52
|
+
:type => :rails,
|
66
53
|
:config => 'config/deploy.rb',
|
67
54
|
:core => :core,
|
68
55
|
:scm => :subversion,
|
data/test/test_vlad.rb
CHANGED
@@ -1,112 +1,111 @@
|
|
1
|
-
require '
|
2
|
-
require 'vlad'
|
1
|
+
require 'rake/test_case'
|
3
2
|
|
4
3
|
$TESTING = true
|
5
4
|
|
6
|
-
class TestVlad <
|
5
|
+
class TestVlad < Rake::TestCase
|
7
6
|
def test_all_hosts
|
8
7
|
util_set_hosts
|
9
|
-
assert_equal %w[app.example.com db.example.com], @
|
8
|
+
assert_equal %w[app.example.com db.example.com], @rake.all_hosts
|
10
9
|
end
|
11
10
|
|
12
11
|
def test_fetch
|
13
12
|
set :foo, 5
|
14
|
-
assert_equal 5, @
|
13
|
+
assert_equal 5, @rake.fetch(:foo)
|
15
14
|
end
|
16
15
|
|
17
16
|
def test_fetch_with_default
|
18
|
-
assert_equal 5, @
|
17
|
+
assert_equal 5, @rake.fetch(:not_here, 5)
|
19
18
|
end
|
20
19
|
|
21
20
|
def test_host
|
22
|
-
@
|
21
|
+
@rake.host "test.example.com", :app, :db
|
23
22
|
expected = {"test.example.com" => {}}
|
24
|
-
assert_equal expected, @
|
25
|
-
assert_equal expected, @
|
23
|
+
assert_equal expected, @rake.roles[:app]
|
24
|
+
assert_equal expected, @rake.roles[:db]
|
26
25
|
end
|
27
26
|
|
28
27
|
def test_host_invalid
|
29
|
-
assert_raises(ArgumentError) { @
|
28
|
+
assert_raises(ArgumentError) { @rake.host nil, :web }
|
30
29
|
end
|
31
30
|
|
32
31
|
def test_host_multiple_hosts
|
33
|
-
@
|
34
|
-
@
|
32
|
+
@rake.host "test.example.com", :app, :db
|
33
|
+
@rake.host "yarr.example.com", :app, :db, :no_release => true
|
35
34
|
|
36
35
|
expected = {
|
37
36
|
"test.example.com" => {},
|
38
37
|
"yarr.example.com" => {:no_release => true}
|
39
38
|
}
|
40
39
|
|
41
|
-
assert_equal expected, @
|
42
|
-
assert_equal expected, @
|
43
|
-
refute_equal(@
|
44
|
-
@
|
40
|
+
assert_equal expected, @rake.roles[:app]
|
41
|
+
assert_equal expected, @rake.roles[:db]
|
42
|
+
refute_equal(@rake.roles[:db]["test.example.com"].object_id,
|
43
|
+
@rake.roles[:app]["test.example.com"].object_id)
|
45
44
|
end
|
46
45
|
|
47
46
|
def test_hosts_for_array_of_roles
|
48
47
|
util_set_hosts
|
49
|
-
assert_equal %w[app.example.com db.example.com], @
|
48
|
+
assert_equal %w[app.example.com db.example.com], @rake.hosts_for([:app, :db])
|
50
49
|
end
|
51
50
|
|
52
51
|
def test_hosts_for_one_role
|
53
52
|
util_set_hosts
|
54
|
-
@
|
55
|
-
assert_equal %w[app.example.com app2.example.com], @
|
53
|
+
@rake.host "app2.example.com", :app
|
54
|
+
assert_equal %w[app.example.com app2.example.com], @rake.hosts_for(:app)
|
56
55
|
end
|
57
56
|
|
58
57
|
def test_hosts_for_multiple_roles
|
59
58
|
util_set_hosts
|
60
|
-
assert_equal %w[app.example.com db.example.com], @
|
59
|
+
assert_equal %w[app.example.com db.example.com], @rake.hosts_for(:app, :db)
|
61
60
|
end
|
62
61
|
|
63
62
|
def test_hosts_for_unique
|
64
63
|
util_set_hosts
|
65
|
-
@
|
66
|
-
assert_equal %w[app.example.com db.example.com], @
|
64
|
+
@rake.host "app.example.com", :web
|
65
|
+
assert_equal %w[app.example.com db.example.com], @rake.hosts_for(:app, :db, :web)
|
67
66
|
end
|
68
67
|
|
69
68
|
def test_initialize
|
70
|
-
@
|
71
|
-
assert_raises(
|
72
|
-
assert_raises(
|
73
|
-
assert_raises(
|
69
|
+
@rake.set_defaults # ensure these three are virginal
|
70
|
+
assert_raises(Rake::ConfigurationError) { @rake.repository }
|
71
|
+
assert_raises(Rake::ConfigurationError) { @rake.deploy_to }
|
72
|
+
assert_raises(Rake::ConfigurationError) { @rake.domain }
|
74
73
|
end
|
75
74
|
|
76
75
|
def test_role
|
77
|
-
@
|
76
|
+
@rake.role :app, "test.example.com"
|
78
77
|
expected = {"test.example.com" => {}}
|
79
|
-
assert_equal expected, @
|
78
|
+
assert_equal expected, @rake.roles[:app]
|
80
79
|
end
|
81
80
|
|
82
81
|
def test_role_multiple_hosts
|
83
|
-
@
|
84
|
-
@
|
82
|
+
@rake.role :app, "test.example.com"
|
83
|
+
@rake.role :app, "yarr.example.com", :no_release => true
|
85
84
|
expected = {
|
86
85
|
"test.example.com" => {},
|
87
86
|
"yarr.example.com" => {:no_release => true}
|
88
87
|
}
|
89
|
-
assert_equal expected, @
|
88
|
+
assert_equal expected, @rake.roles[:app]
|
90
89
|
end
|
91
90
|
|
92
91
|
def test_role_multiple_roles
|
93
|
-
@
|
94
|
-
@
|
92
|
+
@rake.role :app, "test.example.com", :primary => true
|
93
|
+
@rake.role :db, "yarr.example.com", :no_release => true
|
95
94
|
expected_db = { "yarr.example.com" => {:no_release => true} }
|
96
|
-
assert_equal expected_db, @
|
95
|
+
assert_equal expected_db, @rake.roles[:db]
|
97
96
|
expected_app = { "test.example.com" => {:primary => true} }
|
98
|
-
assert_equal expected_app, @
|
97
|
+
assert_equal expected_app, @rake.roles[:app]
|
99
98
|
end
|
100
99
|
|
101
100
|
def test_remote_task
|
102
|
-
t = @
|
101
|
+
t = @rake.remote_task(:test_task) { 5 }
|
103
102
|
assert_equal @task_count + 1, Rake.application.tasks.size
|
104
103
|
assert_equal({ :roles => [] }, t.options)
|
105
104
|
end
|
106
105
|
|
107
106
|
def test_remote_task_all_hosts_by_default
|
108
107
|
util_set_hosts
|
109
|
-
t = @
|
108
|
+
t = @rake.remote_task(:test_task) { 5 }
|
110
109
|
assert_equal %w[app.example.com db.example.com], t.target_hosts
|
111
110
|
end
|
112
111
|
|
@@ -114,31 +113,31 @@ class TestVlad < VladTestCase
|
|
114
113
|
old_env_hosts = ENV["HOSTS"]
|
115
114
|
ENV["HOSTS"] = 'other1.example.com, other2.example.com'
|
116
115
|
util_set_hosts
|
117
|
-
t = @
|
116
|
+
t = @rake.remote_task(:test_task) { 5 }
|
118
117
|
assert_equal %w[other1.example.com other2.example.com], t.target_hosts
|
119
|
-
ensure
|
118
|
+
ensure
|
120
119
|
ENV["HOSTS"] = old_env_hosts
|
121
120
|
end
|
122
121
|
|
123
122
|
def test_remote_task_body_set
|
124
123
|
set(:some_variable, 5)
|
125
|
-
@
|
126
|
-
@
|
124
|
+
@rake.host 'www.example.com', :app
|
125
|
+
@rake.remote_task(:some_task) do $some_task_result = some_variable end
|
127
126
|
|
128
127
|
Rake::Task['some_task'].execute nil
|
129
|
-
assert_equal @
|
128
|
+
assert_equal @rake.fetch(:some_variable), $some_task_result
|
130
129
|
end
|
131
130
|
|
132
131
|
def test_remote_task_with_options
|
133
|
-
t = @
|
132
|
+
t = @rake.remote_task :test_task, :roles => [:app, :db] do
|
134
133
|
fail "should not run"
|
135
134
|
end
|
136
135
|
assert_equal({:roles => [:app, :db]}, t.options)
|
137
136
|
end
|
138
137
|
|
139
138
|
def test_remote_task_before_host_declaration
|
140
|
-
t = @
|
141
|
-
@
|
139
|
+
t = @rake.remote_task :test_task, :roles => :web do 5 end
|
140
|
+
@rake.host 'www.example.com', :web
|
142
141
|
assert_equal %w[www.example.com], t.target_hosts
|
143
142
|
end
|
144
143
|
|
@@ -161,30 +160,30 @@ class TestVlad < VladTestCase
|
|
161
160
|
|
162
161
|
def test_set
|
163
162
|
set :win, 5
|
164
|
-
assert_equal 5, @
|
163
|
+
assert_equal 5, @rake.win
|
165
164
|
end
|
166
165
|
|
167
166
|
def test_set_lazy_block_evaluation
|
168
167
|
set(:lose) { raise "lose" }
|
169
|
-
assert_raises(RuntimeError) { @
|
168
|
+
assert_raises(RuntimeError) { @rake.lose }
|
170
169
|
end
|
171
170
|
|
172
171
|
def test_set_with_block
|
173
172
|
x = 1
|
174
173
|
set(:win) { x += 2 }
|
175
174
|
|
176
|
-
assert_equal 3, @
|
177
|
-
assert_equal 3, @
|
175
|
+
assert_equal 3, @rake.win
|
176
|
+
assert_equal 3, @rake.win
|
178
177
|
end
|
179
178
|
|
180
179
|
def test_set_with_reference
|
181
|
-
@
|
180
|
+
@rake.instance_eval do
|
182
181
|
set(:var_one) { var_two }
|
183
182
|
set(:var_two) { var_three }
|
184
183
|
set(:var_three) { 5 }
|
185
184
|
end
|
186
185
|
|
187
|
-
assert_equal 5, @
|
186
|
+
assert_equal 5, @rake.var_one
|
188
187
|
end
|
189
188
|
|
190
189
|
def test_set_with_block_and_value
|
@@ -196,7 +195,7 @@ class TestVlad < VladTestCase
|
|
196
195
|
|
197
196
|
def test_set_with_nil
|
198
197
|
set(:win, nil)
|
199
|
-
assert_equal nil, @
|
198
|
+
assert_equal nil, @rake.win
|
200
199
|
end
|
201
200
|
|
202
201
|
def test_set_with_reserved_name
|
data.tar.gz.sig
ADDED
Binary file
|