Skip to content

Commit

Permalink
Add tests for top-level dialog color APIs
Browse files Browse the repository at this point in the history
  • Loading branch information
st0012 committed Jun 28, 2022
1 parent bd49537 commit 347a468
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions test/reline/test_reline.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,23 @@ def test_completion_append_character
Reline.completion_append_character = completion_append_character
end

def test_dialog_color_configuration
# defaults
assert_equal(46, Reline.dialog_default_bg_color)
assert_equal(37, Reline.dialog_default_fg_color)
assert_equal(45, Reline.dialog_pointer_bg_color)
assert_equal(37, Reline.dialog_pointer_fg_color)

Reline.dialog_default_bg_color = 40
assert_equal(40, Reline.dialog_default_bg_color)
Reline.dialog_default_fg_color = 47
assert_equal(47, Reline.dialog_default_fg_color)
Reline.dialog_pointer_bg_color = 37
assert_equal(37, Reline.dialog_pointer_bg_color)
Reline.dialog_pointer_fg_color = 30
assert_equal(30, Reline.dialog_pointer_fg_color)
end

def test_basic_word_break_characters
basic_word_break_characters = Reline.basic_word_break_characters

Expand Down

0 comments on commit 347a468

Please sign in to comment.