File tree 1 file changed +16
-1
lines changed
1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -70,6 +70,21 @@ FakeFS::SpecHelpers to turn FakeFS on and off in a given example group:
70
70
See ` lib/fakefs/spec_helpers.rb ` for more info.
71
71
72
72
73
+ Integrating with other file system libraries
74
+ --------------------------------------------
75
+ Libraries like [ FileMagic] ( https://rubygems.org/gems/ruby-filemagic ) add
76
+ additional functionality to the File class. These should be monkey-patched in
77
+ your test harness' helper file.
78
+
79
+ module FakeFS
80
+ class File
81
+ def content_type
82
+ 'fake/file'
83
+ end
84
+ end
85
+ end
86
+
87
+
73
88
How is this different than MockFS?
74
89
----------------------------------
75
90
@@ -134,4 +149,4 @@ Releasing
134
149
135
150
1 . Update version in lib/fakefs/version.rb
136
151
2 . Commit it
137
- 3 . rake publish
152
+ 3 . rake publish
You can’t perform that action at this time.
0 commit comments