Updated File.open and File.new signature
This commit is contained in:
parent
f6031458cd
commit
8e1d049ee4
@ -5,7 +5,7 @@
|
||||
|
||||
Gem::Specification.new do |s|
|
||||
s.name = %q{fakefs}
|
||||
s.version = "0.1.5"
|
||||
s.version = "0.1.6"
|
||||
|
||||
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
||||
s.authors = ["Chris Wanstrath"]
|
||||
|
@ -65,11 +65,11 @@ module FakeFS
|
||||
FileSystem.find(symlink.target).to_s
|
||||
end
|
||||
|
||||
def self.open(path, mode='r')
|
||||
def self.open(path, mode='r', perm = 0644)
|
||||
if block_given?
|
||||
yield new(path, mode)
|
||||
yield new(path, mode, perm)
|
||||
else
|
||||
new(path, mode)
|
||||
new(path, mode, perm)
|
||||
end
|
||||
end
|
||||
|
||||
@ -87,7 +87,7 @@ module FakeFS
|
||||
end
|
||||
|
||||
attr_reader :path
|
||||
def initialize(path, mode = nil)
|
||||
def initialize(path, mode = nil, perm = nil)
|
||||
@path = path
|
||||
@mode = mode
|
||||
@file = FileSystem.find(path)
|
||||
|
@ -1,6 +1,6 @@
|
||||
module FakeFS
|
||||
module Version
|
||||
VERSION = "0.1.5"
|
||||
VERSION = "0.1.6"
|
||||
|
||||
def self.to_s
|
||||
VERSION
|
||||
|
Loading…
Reference in New Issue
Block a user