Added tests or mockup tests for every module

This commit is contained in:
dandaedre 2022-02-20 17:58:41 +01:00
parent d9ebf0eac9
commit 775f358aed
8 changed files with 72 additions and 0 deletions

View File

@ -0,0 +1,11 @@
import bootstraparse.modules.config as config
import pytest
"""
"""
@pytest.mark.xfail(reason="Not implemented")
def test_config_load():
assert config.load() is not None

View File

@ -0,0 +1,7 @@
import bootstraparse.modules.context_mngr as context_mngr
import pytest
@pytest.mark.xfail(reason="Not implemented yet")
def test_context_mngr_init():
context_mngr.ContextManager()

View File

@ -0,0 +1,7 @@
import bootstraparse.modules.export as export
import pytest
@pytest.mark.xfail(reason="Not implemented")
def test_export():
assert export.export() == "export"

View File

@ -0,0 +1,7 @@
import bootstraparse.modules.parser as parser
import pytest
@pytest.mark.xfail(reason="Not implemented")
def test_parser():
pass

View File

@ -0,0 +1,10 @@
import bootstraparse.modules.sitecrawler as sitecrawler
import pytest
@pytest.mark.xfail(reason="Not implemented yet")
def test_sitecrawler_init():
"""
Test the sitecrawler.SiteCrawler class
"""
pass

View File

@ -0,0 +1,16 @@
import bootstraparse.modules.sitecreator as sitecreator
import pytest
def test_create_site():
sitecreator.create_website()
sitecreator.create_environment()
sitecreator.create_config()
sitecreator.create_crawler()
sitecreator.create_user_config()
sitecreator.create_template()
sitecreator.env_checker()
sitecreator.begin_crawling(None)
sitecreator.begin_pre_parsing(None)
sitecreator.begin_parsing(None)
sitecreator.begin_export(None)

View File

@ -0,0 +1,7 @@
import bootstraparse.modules.syntax as syntax
import pytest
@pytest.mark.xfail(reason="Not implemented")
def test_syntax_check():
assert syntax.syntax_check() == True

View File

@ -0,0 +1,7 @@
import bootstraparse.modules.template_mngr as template_mngr
import pytest
@pytest.mark.xfail(reason="Not implemented yet")
def test_get_template_path():
assert template_mngr.get_template_path() is not None