Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 27bf29d212de
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 06aa3f7de368
Choose a head ref
  • 2 commits
  • 1 file changed
  • 2 contributors

Commits on Sep 1, 2017

  1. an example test case for #4770 that shows how unicode readings fails …

    …in readonly transaction
    duritong committed Sep 1, 2017
    Copy the full SHA
    63be5a4 View commit details

Commits on Jan 10, 2018

  1. Merge pull request #4771 from duritong/yamlstore-unicode-failure-in-r…

    …eadonly-transaction
    
    an example test case for #4770 that shows how unicode readings fails …
    enebo authored Jan 10, 2018
    Copy the full SHA
    06aa3f7 View commit details
Showing with 18 additions and 0 deletions.
  1. +18 −0 test/jruby/test_yamlstore.rb
18 changes: 18 additions & 0 deletions test/jruby/test_yamlstore.rb
Original file line number Diff line number Diff line change
@@ -34,6 +34,15 @@ def test_data_should_be_loaded_correctly_when_in_readonly_mode
end
end

def test_unicode_data_should_be_loaded_correctly_when_in_readonly_mode
@yamlstore.transaction do
@yamlstore[:unicode] = "Tütü"
end
@yamlstore.transaction(true) do
assert_equal "Tütü", @yamlstore[:unicode]
end
end

def test_data_should_be_loaded_correctly_when_in_readwrite_mode
@yamlstore.transaction do
@yamlstore[:foo] = "bar"
@@ -43,6 +52,15 @@ def test_data_should_be_loaded_correctly_when_in_readwrite_mode
end
end

def test_unicode_data_should_be_loaded_correctly_when_in_readwrite_mode
@yamlstore.transaction do
@yamlstore[:unicoderw] = "Tütü"
end
@yamlstore.transaction do
assert_equal "Tütü", @yamlstore[:unicoderw]
end
end

def test_changes_after_commit_are_discarded
@yamlstore.transaction do
@yamlstore[:foo] = "bar"