Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
18 changes: 18 additions & 0 deletions test/jruby/test_yamlstore.rb
Expand Up @@ -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"
Expand All @@ -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"
Expand Down