Sha256: 31f2184107b73af954c11d4a2ebf596a7eab1ac5b379e4dd336e9b4ec4c73c7d

Contents?: true

Size: 536 Bytes

Versions: 6

Compression:

Stored size: 536 Bytes

Contents

require_relative 'test_helper'

describe "FastExcel" do

  it "should create temporary file if filename is nil" do
    workbook = FastExcel.open(constant_memory: true)

    assert(workbook.tmp_file)
    assert_match(/fast_excel.xlsx$/, workbook.filename)

    result = workbook.read_string
    assert(result.size > 1000)
  end

  it "should close workbook and delete tmp file when read_string" do
    workbook = FastExcel.open
    workbook.read_string

    refute(File.exist?(workbook.filename))
    refute(workbook.is_open)
  end

end

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
fast_excel-0.2.6 test/tmpfile_test.rb
fast_excel-0.2.5 test/tmpfile_test.rb
fast_excel-0.2.3 test/tmpfile_test.rb
fast_excel-0.2.2 test/tmpfile_test.rb
kmadej_fast_excel_fork-0.2.2 test/tmpfile_test.rb
fast_excel-0.2.1 test/tmpfile_test.rb