From 0b7d45b98511c356c9d75975608886d22b09c086 Mon Sep 17 00:00:00 2001 From: Scott Taylor Date: Wed, 30 Sep 2009 03:22:28 -0400 Subject: [PATCH] Don't attempt to create a missing file in File.write (the mode guarantees that the file will already be present) --- lib/fakefs/file.rb | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/fakefs/file.rb b/lib/fakefs/file.rb index ef0a844..3f5b048 100644 --- a/lib/fakefs/file.rb +++ b/lib/fakefs/file.rb @@ -134,7 +134,6 @@ module FakeFS raise IOError, 'closed stream' unless @open raise IOError, 'not open for writing' if read_only? - create_missing_file @file.content += content end alias_method :print, :write