Module: SpecCat

Defined in:
lib/spec_cat.rb,
lib/spec_cat/railtie.rb,
lib/spec_cat/version.rb

Defined Under Namespace

Classes: Railtie

Constant Summary collapse

VERSION =
'1.0.3'

Class Method Summary collapse

Class Method Details

.accept?Boolean

Returns:

  • (Boolean)


11
12
13
# File 'lib/spec_cat.rb', line 11

def self.accept?
  !ENV[ 'SPEC_CAT_ACCEPT' ].nil?
end

.read(path) ⇒ Object



19
20
21
# File 'lib/spec_cat.rb', line 19

def self.read( path )
  File.open( path, 'rb' ) { |io| io.read }
end

.write(path, content) ⇒ Object



15
16
17
# File 'lib/spec_cat.rb', line 15

def self.write( path, content )
  File.open( path,'wb' ) { |io| io.write content }
end