Sha256: e57bc64eb3df5bddf4975204ed5ed5fd6dc2a5fc355b7bed6d642385e0aa06d5

Contents?: true

Size: 648 Bytes

Versions: 8

Compression:

Stored size: 648 Bytes

Contents

# -*- coding: utf-8 -*-
require 'helper'

class TestRegressionProtect04 < Minitest::Test
  def setup
    setup_dir_var
  end

  def teardown
    @tempfile.close(true)
  end

  def test_protect04
    @xlsx = 'protect04.xlsx'
    workbook  = WriteXLSX.new(@io)
    worksheet = workbook.add_worksheet

    unlocked = workbook.add_format(:locked => 0, :hidden => 0)
    hidden   = workbook.add_format(:locked => 0, :hidden => 1)

    worksheet.protect

    worksheet.unprotect_range('A1')

    worksheet.write('A1', 1)
    worksheet.write('A2', 2, unlocked)
    worksheet.write('A3', 3, hidden)

    workbook.close
    compare_for_regression
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
write_xlsx-1.09.4 test/regression/test_protect04.rb
write_xlsx-1.09.3 test/regression/test_protect04.rb
write_xlsx-1.09.2 test/regression/test_protect04.rb
write_xlsx-1.09.1 test/regression/test_protect04.rb
write_xlsx-1.09.0 test/regression/test_protect04.rb
write_xlsx-1.08.2 test/regression/test_protect04.rb
write_xlsx-1.08.1 test/regression/test_protect04.rb
write_xlsx-1.08.0 test/regression/test_protect04.rb