Browse Source

fixed and improved page rendering test

Rodja Trappe 2 years ago
parent
commit
ed892f6451
1 changed files with 17 additions and 0 deletions
  1. 17 0
      tests/test_user.py

+ 17 - 0
tests/test_user.py

@@ -11,10 +11,25 @@ def test_rendering_page(user: User):
         ui.label('1')
         ui.label('2')
         ui.label('3')
+    with ui.card():
+        ui.label('some text')
 
     user.open('/')
     assert user.page() == '''Title: NiceGUI
 
+test label
+row
+  test input: some placeholder
+column
+  1
+  2
+  3
+card
+  some text
+'''
+
+    assert user.page(with_extras=True) == '''Title: NiceGUI
+
 test label
 row [class: items-start positive]
   test input: some placeholder [class: no-wrap items-start standard labeled]
@@ -22,4 +37,6 @@ column [class: items-start]
   1
   2
   3
+card [class: items-start q-pa-md]
+  some text
 '''