Class: Tempfile

Inherits:
StringIO
  • Object
show all
Defined in:
lib/homura_vendor_tempfile.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeTempfile

Returns a new instance of Tempfile.



6
7
8
# File 'lib/homura_vendor_tempfile.rb', line 6

def initialize(*)
  super("")
end

Class Method Details

.openObject

Raises:

  • (NotImplementedError)


10
11
12
13
14
15
# File 'lib/homura_vendor_tempfile.rb', line 10

def self.open(*)
  raise(
    NotImplementedError,
    "Tempfile is stubbed in homura (Workers have no writable FS)"
  )
end

Instance Method Details

#close!Object



29
30
31
# File 'lib/homura_vendor_tempfile.rb', line 29

def close!
  close
end

#deleteObject



25
26
27
# File 'lib/homura_vendor_tempfile.rb', line 25

def delete
  self
end

#pathObject

Raises:

  • (NotImplementedError)


17
18
19
# File 'lib/homura_vendor_tempfile.rb', line 17

def path
  raise NotImplementedError, "Tempfile#path stubbed (no FS)"
end


21
22
23
# File 'lib/homura_vendor_tempfile.rb', line 21

def unlink
  self
end