A search engine for MMP's eASLRB.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
asl-rulebook2/asl_rulebook2/webapp/tests/test_basic.py

26 lines
888 B

""" Test basic functionality. """
from asl_rulebook2.webapp.tests.utils import init_webapp, \
get_nav_panels, get_content_docs, check_sr_filters, select_tabbed_page, find_child
# ---------------------------------------------------------------------
def test_hello( webapp, webdriver ):
"""Test basic functionality."""
# initialize
webapp.control_tests.set_data_dir( "simple" )
init_webapp( webapp, webdriver )
check_sr_filters( [] )
# check that the nav panel loaded correctly
nav_panels = get_nav_panels()
assert nav_panels == [ "search", "chapters" ]
# check that there are no chapters
select_tabbed_page( "nav", "search" )
assert find_child( "#nav .tabbed-page[data-tabid='chapters'] .no-chapters" )
# check that the content docs loaded correctly
content_docs = get_content_docs()
assert content_docs == [ "simple!" ]