Skip to content

Commit

Permalink
Add spec for list_id rendering on BorderBox
Browse files Browse the repository at this point in the history
  • Loading branch information
aaron-contreras committed Nov 27, 2023
1 parent 903935e commit 7e1ca2b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions test/components/beta/border_box_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,15 @@ def test_renders_multiple_rows
assert_selector("li.Box-row", count: 3)
end

def test_renders_the_list_element_with_an_id_if_provided
render_inline(Primer::Beta::BorderBox.new(list_id: "an-id")) do |component|
component.with_row { "First" }
end

assert_selector("ul#an-id", count: 1)
assert_selector("li.Box-row", count: 1)
end

def test_renders_condensed
render_inline(Primer::Beta::BorderBox.new(padding: :condensed)) do |component|
component.with_body { "Body" }
Expand Down

0 comments on commit 7e1ca2b

Please sign in to comment.