public
Description: Piston is a utility that eases vendor branch management. This repository is a complete reimplementation of Piston to provide different backends, depending on the repositories and working copies you pistonize from.
Homepage: http://piston.rubyforge.org/
Clone URL: git://github.com/francois/piston.git
Search Repo:
Moved #test_writes_values_as_yaml_under_handler_key from the svn WC tests 
to the main Piston WC tests.
francois (author)
Sat Mar 22 18:45:27 -0700 2008
commit  c9907db998f58f0efcfc6e7df52c1e3eff9ebe41
tree    67b174820399c0c1c8cd1d3959011e929f8bdff9
parent  82d2f8b4e2a9828cac94faff9dd0499c03784658
...
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
...
13
14
15
 
 
 
 
 
 
 
 
 
 
 
16
0
@@ -13,16 +13,5 @@
0
     @wcdir.rmtree rescue nil
0
   end
0
 
0
- def test_creates_dot_piston_dot_yml_file
0
- @wc.remember("a" => "b")
0
- assert((@wcdir + ".piston.yml").exist?)
0
- end
0
-
0
- def test_writes_values_as_yaml_under_handler_key
0
- expected = {"a" => "b"}
0
- @wc.remember(expected)
0
- actual = YAML.load((@wcdir + ".piston.yml").read)
0
- assert_equal expected, actual["handler"]
0
- end
0
 end
...
2
3
4
5
6
7
8
 
 
 
 
9
10
11
12
 
13
14
15
16
17
 
18
19
 
 
 
 
 
 
 
20
21
 
22
23
24
...
2
3
4
 
 
 
 
5
6
7
8
9
10
11
 
12
13
14
15
16
 
17
18
19
20
21
22
23
24
25
26
27
 
28
29
30
31
0
@@ -2,23 +2,30 @@
0
 
0
 class TestWorkingCopyRememberance < Test::Unit::TestCase
0
   def setup
0
- @wcpath = Pathname.new("tmp/wc")
0
- @wcpath.rmtree rescue nil
0
- @wcpath.mkpath
0
- @wc = Piston::WorkingCopy.new(@wcpath)
0
+ @wcdir = Pathname.new("tmp/wc")
0
+ @wcdir.rmtree rescue nil
0
+ @wcdir.mkpath
0
+ @wc = Piston::WorkingCopy.new(@wcdir)
0
   end
0
 
0
   def teardown
0
- @wcpath.rmtree rescue nil
0
+ @wcdir.rmtree rescue nil
0
   end
0
 
0
   def test_remember_generates_piston_yml_file_in_wc
0
     @wc.remember("a" => "b")
0
- assert((@wcpath + ".piston.yml").exist?, "tmp/wc/.piston.yml file doesn't exist")
0
+ assert((@wcdir + ".piston.yml").exist?, "tmp/wc/.piston.yml file doesn't exist")
0
   end
0
 
0
+ def test_writes_values_as_yaml_under_handler_key
0
+ expected = {"a" => "b"}
0
+ @wc.remember(expected)
0
+ actual = YAML.load((@wcdir + ".piston.yml").read)
0
+ assert_equal expected, actual["handler"]
0
+ end
0
+
0
   def test_remember_calls_after_remember_with_path_to_piston_yml_file
0
- @wc.expects(:after_remember).with(@wcpath + ".piston.yml")
0
+ @wc.expects(:after_remember).with(@wcdir + ".piston.yml")
0
     @wc.remember("a" => "b")
0
   end
0
 end

Comments

    No one has commented yet.