Skip to content

Commit

Permalink
chore: keep previous test
Browse files Browse the repository at this point in the history
  • Loading branch information
zakybilfagih committed Jan 15, 2025
1 parent f79d1f7 commit a641cd9
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions packages/runtime/test/test_styles.ml
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,35 @@ let selector_ampersand_at_the_middle =
let selector_nested_with_mq_and_declarations =
test "selector_nested_with_mq_and_declarations" @@ fun () ->
let mobile = "(max-width: 767px)" in
let classname =
[%cx
{|
li {
list-style-type: none;

::before {
position: absolute;
left: -20px;
content: "✓";
}

@media $(mobile) {
position: relative;
}
}
|}]
in
let css = get_string_style_rules () in
assert_string css
(Printf.sprintf
".%s li { list-style-type: none; } .%s li::before { position: absolute; \
left: -20px; content: \"\"; } @media (max-width: 767px) { .%s li { \
position: relative; } }"
classname classname classname)

let selector_nested_with_mq_and_declarations2 =
test "selector_nested_with_mq_and_declarations2" @@ fun () ->
let mobile = "(max-width: 767px)" in
let classname =
[%cx
{|
Expand Down Expand Up @@ -1204,6 +1233,7 @@ let tests =
selector_nested_with_pseudo_2;
selector_nested_with_pseudo_3;
selector_nested_with_mq_and_declarations;
selector_nested_with_mq_and_declarations2;
selector_nested_interpolation_with_multiple;
mq_with_selectors;
mq;
Expand Down

0 comments on commit a641cd9

Please sign in to comment.