Module: SpecCat

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

Defined Under Namespace

Classes: Railtie

Class Method Summary collapse

Class Method Details

.accept?Boolean

Returns:

  • (Boolean)


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

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

.read(path) ⇒ Object



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

def self.read( path )
  File.open( path, 'rb', &:read )
end

.write(path, content) ⇒ Object



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

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