Skip to content

Commit 2877f7d

Browse files
Cleanup trailing whitespace
1 parent d2264eb commit 2877f7d

10 files changed

+29
-29
lines changed

README.markdown

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,11 @@ Don't Fake the FS Immediately
3737
-----------------------------
3838

3939
require 'fakefs/safe'
40-
40+
4141
FakeFS.activate!
4242
# your code
4343
FakeFS.deactivate!
44-
44+
4545
# or
4646
FakeFS do
4747
# your code

lib/fakefs/fake/symlink.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def respond_to?(method)
2424
end
2525

2626
private
27-
27+
2828
def method_missing(*args, &block)
2929
entry.send(*args, &block)
3030
end

lib/fakefs/fileutils.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ def ln_sf(target, path)
3636
ln_s(target, path, { :force => true })
3737
end
3838

39-
39+
4040

4141
def cp(src, dest)
4242
dst_file = FileSystem.find(dest)

spec/fakefs/spec_helpers_spec.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,4 +54,4 @@ def self.after(sym = :each)
5454
end
5555
end
5656
end
57-
end
57+
end

spec/spec.opts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
--color
1+
--color

spec/spec_helper.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
$LOAD_PATH.unshift File.join(File.dirname(__FILE__), '..', 'lib')
22

3-
require 'fakefs/spec_helpers'
3+
require 'fakefs/spec_helpers'

test/fake/file_test.rb

+3-3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class FakeFileTest < Test::Unit::TestCase
77

88
def setup
99
FileSystem.clear
10-
10+
1111
@file = FakeFile.new
1212
end
1313

@@ -43,9 +43,9 @@ def test_fake_file_wont_add_link_to_same_file_twice
4343

4444
def test_links_are_mutual
4545
other_file = FakeFile.new
46-
46+
4747
@file.link(other_file)
48-
48+
4949
assert_equal [@file, other_file], other_file.links
5050
end
5151

test/fakefs_test.rb

+12-12
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def test_can_create_directories
2424
FileUtils.mkdir_p("/path/to/dir")
2525
assert_kind_of FakeDir, FileSystem.fs['path']['to']['dir']
2626
end
27-
27+
2828
def test_can_create_directories_with_mkpath
2929
FileUtils.mkpath("/path/to/dir")
3030
assert_kind_of FakeDir, FileSystem.fs['path']['to']['dir']
@@ -74,14 +74,14 @@ def test_can_create_symlinks
7474
FileUtils.ln_s(target, '/path/to/link')
7575
end
7676
end
77-
77+
7878
def test_can_force_creation_of_symlinks
7979
FileUtils.mkdir_p(target = "/path/to/first/target")
8080
FileUtils.ln_s(target, "/path/to/link")
8181
assert_kind_of FakeSymlink, FileSystem.fs['path']['to']['link']
8282
FileUtils.ln_s(target, '/path/to/link', :force => true)
8383
end
84-
84+
8585
def test_create_symlink_using_ln_sf
8686
FileUtils.mkdir_p(target = "/path/to/first/target")
8787
FileUtils.ln_s(target, "/path/to/link")
@@ -1126,38 +1126,38 @@ def test_directory_open_block
11261126
def test_tmpdir
11271127
assert Dir.tmpdir == "/tmp"
11281128
end
1129-
1129+
11301130
def test_hard_link_creates_file
11311131
FileUtils.touch("/foo")
1132-
1132+
11331133
File.link("/foo", "/bar")
11341134
assert File.exists?("/bar")
11351135
end
1136-
1136+
11371137
def test_hard_link_with_missing_file_raises_error
11381138
assert_raises(Errno::ENOENT) do
11391139
File.link("/foo", "/bar")
11401140
end
11411141
end
1142-
1142+
11431143
def test_hard_link_with_existing_destination_file
11441144
FileUtils.touch("/foo")
11451145
FileUtils.touch("/bar")
1146-
1146+
11471147
assert_raises(Errno::EEXIST) do
11481148
File.link("/foo", "/bar")
11491149
end
11501150
end
1151-
1151+
11521152
def test_hard_link_returns_0_when_successful
11531153
FileUtils.touch("/foo")
1154-
1154+
11551155
assert_equal 0, File.link("/foo", "/bar")
11561156
end
1157-
1157+
11581158
def test_hard_link_returns_duplicate_file
11591159
File.open("/foo", "w") { |x| x << "some content" }
1160-
1160+
11611161
File.link("/foo", "/bar")
11621162
assert_equal "some content", File.read("/bar")
11631163
end

test/safe_test.rb

+4-4
Original file line numberDiff line numberDiff line change
@@ -26,17 +26,17 @@ def test_FakeFS_method_returns_value_of_yield
2626

2727
assert_equal result, "Yatta!"
2828
end
29-
29+
3030
def test_FakeFS_method_deactivates_FakeFS_when_block_raises_exception
3131
begin
3232
FakeFS do
3333
raise 'boom!'
3434
end
3535
rescue
3636
end
37-
37+
3838
assert_equal RealFile, File, "File is #{File} (should be #{RealFile})"
39-
assert_equal RealFileUtils, FileUtils, "FileUtils is #{FileUtils} (should be #{RealFileUtils})"
39+
assert_equal RealFileUtils, FileUtils, "FileUtils is #{FileUtils} (should be #{RealFileUtils})"
4040
assert_equal RealDir, Dir, "Dir is #{Dir} (should be #{RealDir})"
41-
end
41+
end
4242
end

test/verify.rb

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,20 @@
55
# $ ruby test/verify.rb | grep "not implemented"
66
require 'fakefs'
77
require 'test/unit'
8-
8+
99
class FakeFSVerifierTest < Test::Unit::TestCase
1010
(RealFile.methods - Class.new.methods).each do |name|
1111
define_method("test #{name} class method") do
1212
assert File.respond_to?(name), "File.#{name} not implemented"
1313
end
1414
end
15-
15+
1616
(RealFile.instance_methods - Enumerable.instance_methods).each do |name|
1717
define_method("test #{name} instance method") do
1818
assert File.instance_methods.include?(name), "File##{name} not implemented"
1919
end
2020
end
21-
21+
2222
(RealFileUtils.methods - Class.new.methods).each do |name|
2323
define_method("test #{name} module method") do
2424
assert FileUtils.respond_to?(name), "FileUtils.#{name} not implemented"

0 commit comments

Comments
 (0)