diff --git a/strictdoc/backend/sdoc/models/document.py b/strictdoc/backend/sdoc/models/document.py
index b21b52b98..83661b6dc 100644
--- a/strictdoc/backend/sdoc/models/document.py
+++ b/strictdoc/backend/sdoc/models/document.py
@@ -180,6 +180,9 @@ def is_root_included_document(self) -> bool:
def is_requirement(self) -> bool:
return False
+ def is_document(self) -> bool:
+ return True
+
def get_display_node_type(self) -> str:
return "Document"
diff --git a/strictdoc/backend/sdoc/models/section.py b/strictdoc/backend/sdoc/models/section.py
index 14a4b1023..c7ab9be44 100644
--- a/strictdoc/backend/sdoc/models/section.py
+++ b/strictdoc/backend/sdoc/models/section.py
@@ -74,6 +74,9 @@ def __init__(
# Sections are never auto-generated, so this is always hard-coded to False.
self.autogen: bool = False
+ def is_document(self) -> bool:
+ return False
+
@staticmethod
def get_type_string() -> str:
return "section"
diff --git a/strictdoc/export/html/templates/components/node/node_controls/index.jinja b/strictdoc/export/html/templates/components/node/node_controls/index.jinja
index 6a3693c45..2c722cb97 100644
--- a/strictdoc/export/html/templates/components/node/node_controls/index.jinja
+++ b/strictdoc/export/html/templates/components/node/node_controls/index.jinja
@@ -183,7 +183,7 @@
data-turbo-action="replace"
data-turbo="true"
title="Add child SECTION"
- data-testid="node-add-section-child-action"
+ data-testid="node-add-section-DEPRECATED-child-action"
>{% include "_res/svg_ico16_add_child.jinja" %}
{# 3 • Section -> add Section #}
diff --git a/strictdoc/export/html/templates/screens/document/document/frame_document_content.jinja.html b/strictdoc/export/html/templates/screens/document/document/frame_document_content.jinja.html
index 42bc499bb..dd9bd6dcd 100644
--- a/strictdoc/export/html/templates/screens/document/document/frame_document_content.jinja.html
+++ b/strictdoc/export/html/templates/screens/document/document/frame_document_content.jinja.html
@@ -9,7 +9,9 @@
{%- for node, _ in view_object.document_content_iterator() %}
- {%- if node.is_section() or node.is_document() %}
+ {%- if node.is_document() %}
+ {% include "components/section/index_extends_node.jinja" %}
+ {%- elif node.is_section() %}
{% include "components/section/index_extends_node.jinja" %}
{%- elif node.is_requirement() %}
{# {%- if node.is_text_node() %}
diff --git a/tests/end2end/helpers/components/node/add_node_menu.py b/tests/end2end/helpers/components/node/add_node_menu.py
index 507049f0f..e1806092f 100644
--- a/tests/end2end/helpers/components/node/add_node_menu.py
+++ b/tests/end2end/helpers/components/node/add_node_menu.py
@@ -4,9 +4,6 @@
from tests.end2end.helpers.screens.document.form_edit_requirement import (
Form_EditRequirement,
)
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
-)
class AddNode_Menu: # pylint: disable=invalid-name
@@ -64,50 +61,6 @@ def assert_node_has_action_add_section_child(self) -> None:
'//*[@data-testid="node-add-section-child-action"]'
)
- # Add section
-
- # From ROOT
- def do_node_add_section_first(self) -> Form_EditSection:
- self.test_case.click(
- selector=(
- '//*[@data-testid="node-root"]'
- '//*[@data-testid="node-add-section-DEPRECATED-first-action"]'
- ),
- by=By.XPATH,
- )
- return Form_EditSection(self.test_case)
-
- # From Node
- def do_node_add_section_above(self) -> Form_EditSection:
- self.test_case.click(
- selector=(
- f"{self.node_xpath}"
- '//*[@data-testid="node-add-section-DEPRECATED-above-action"]'
- ),
- by=By.XPATH,
- )
- return Form_EditSection(self.test_case)
-
- def do_node_add_section_below(self) -> Form_EditSection:
- self.test_case.click(
- selector=(
- f"{self.node_xpath}"
- '//*[@data-testid="node-add-section-DEPRECATED-below-action"]'
- ),
- by=By.XPATH,
- )
- return Form_EditSection(self.test_case)
-
- def do_node_add_section_child(self) -> Form_EditSection:
- self.test_case.click(
- selector=(
- f"{self.node_xpath}"
- '//*[@data-testid="node-add-section-child-action"]'
- ),
- by=By.XPATH,
- )
- return Form_EditSection(self.test_case)
-
# Add requirement
# From ROOT
diff --git a/tests/end2end/helpers/components/node/node.py b/tests/end2end/helpers/components/node/node.py
index 9b407e719..7b96b1fba 100644
--- a/tests/end2end/helpers/components/node/node.py
+++ b/tests/end2end/helpers/components/node/node.py
@@ -10,9 +10,6 @@
from tests.end2end.helpers.screens.document.form_edit_requirement import (
Form_EditRequirement,
)
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
-)
class Node: # pylint: disable=invalid-name
@@ -166,10 +163,6 @@ def do_open_form_edit_requirement(self) -> Form_EditRequirement:
)
return Form_EditRequirement(self.test_case)
- def do_open_form_edit_section(self) -> Form_EditSection:
- self._do_node_edit()
- return Form_EditSection(self.test_case)
-
def do_open_form_edit_included_document(self) -> Form_EditIncludedDocument:
self._do_node_edit()
return Form_EditIncludedDocument(self.test_case)
diff --git a/tests/end2end/helpers/screens/document/form_edit_section.py b/tests/end2end/helpers/screens/document/form_edit_section.py
deleted file mode 100644
index 68e2c216e..000000000
--- a/tests/end2end/helpers/screens/document/form_edit_section.py
+++ /dev/null
@@ -1,32 +0,0 @@
-# pylint: disable=invalid-name
-from seleniumbase import BaseCase
-
-from tests.end2end.helpers.form.form import Form
-
-
-class Form_EditSection(Form): # pylint: disable=invalid-name
- def __init__(self, test_case: BaseCase) -> None:
- assert isinstance(test_case, BaseCase)
- super().__init__(test_case)
-
- def do_fill_in_uid(self, field_value: str) -> None:
- assert isinstance(field_value, str)
- super().do_fill_in("UID", field_value)
-
- def do_fill_in_title(self, field_value: str) -> None:
- assert isinstance(field_value, str)
- super().do_fill_in("TITLE", field_value)
-
- def do_fill_in_text(self, field_value: str) -> None:
- assert isinstance(field_value, str)
- assert len(field_value) > 0, (
- "To clear a text field, use do_clear_text() instead."
- )
- super().do_fill_in("STATEMENT", field_value)
-
- def do_reset_uid_field(self, field_name: str = "") -> None:
- assert isinstance(field_name, str)
- self.test_case.click_xpath("//*[@data-testid='reset-uid-field-action']")
-
- def do_clear_text(self) -> None:
- super().do_clear_field("STATEMENT")
diff --git a/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/expected_output/document.sdoc b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/expected_output/document.sdoc
index d4e81bcfb..e76413dcc 100644
--- a/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/expected_output/document.sdoc
@@ -1,11 +1,11 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
UID: SECT-1
TITLE: First title
-[/SECTION]
+[[/SECTION]]
[REQUIREMENT]
UID: REQ-1
diff --git a/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/expected_output/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/input/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/test_case.py b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/test_case.py
index ab9339de2..b9b8acfa3 100644
--- a/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/LINK_and_ANCHOR/node/_create/create_section_with_uid_and_node_with_LINK/test_case.py
@@ -5,9 +5,6 @@
from tests.end2end.helpers.screens.document.form_edit_requirement import (
Form_EditRequirement,
)
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
-)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
)
@@ -40,17 +37,17 @@ def test(self):
root_node = screen_document.get_root_node()
root_node_menu = root_node.do_open_node_menu()
- form_edit_section_1: Form_EditSection = (
- root_node_menu.do_node_add_section_first()
+ form_edit_section_1: Form_EditRequirement = (
+ root_node_menu.do_node_add_element_first("SECTION")
)
- form_edit_section_1.do_fill_in_uid("SECT-1")
- form_edit_section_1.do_fill_in_title("First title")
+ form_edit_section_1.do_fill_in("UID", "SECT-1")
+ form_edit_section_1.do_fill_in("TITLE", "First title")
form_edit_section_1.do_form_submit()
- section_1 = screen_document.get_section()
+ section_1 = screen_document.get_node()
- section_1.assert_section_title("First title", "1")
+ section_1.assert_requirement_title("First title", "1")
screen_document.assert_toc_contains("First title")
#
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/expected_output/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/expected_output/document.sdoc
index a5cb5ba29..3e0d34720 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/expected_output/document.sdoc
@@ -6,15 +6,15 @@ STATEMENT: >>>
Hello world!
<<<
-[SECTION]
+[[SECTION]]
TITLE: Section that nests a document fragment.
-[SECTION]
+[[SECTION]]
TITLE: First section
-[/SECTION]
+[[/SECTION]]
[DOCUMENT_FROM_FILE]
FILE: fragment.sdoc
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/expected_output/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/input/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/input/document.sdoc
index 288e83b9a..905aa4722 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/input/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/input/document.sdoc
@@ -6,10 +6,10 @@ STATEMENT: >>>
Hello world!
<<<
-[SECTION]
+[[SECTION]]
TITLE: Section that nests a document fragment.
[DOCUMENT_FROM_FILE]
FILE: fragment.sdoc
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/input/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/test_case.py b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/test_case.py
index 0ae27cd09..1e18cbb74 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document__fragment_nested_in_section__create_section_above/test_case.py
@@ -1,9 +1,10 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
from tests.end2end.helpers.components.node.add_node_menu import AddNode_Menu
+from tests.end2end.helpers.components.node.requirement import Requirement
from tests.end2end.helpers.components.node.section import Section
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -32,19 +33,19 @@ def test(self):
screen_document.assert_text("Hello world!")
- section: Section = screen_document.get_section(node_order=2)
+ section: Section = screen_document.get_section(node_order=1)
section_menu: AddNode_Menu = section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- section_menu.do_node_add_section_above()
+ form_edit_section: Form_EditRequirement = (
+ section_menu.do_node_add_element_above("SECTION")
)
- form_edit_section.do_fill_in_title("First section")
+ form_edit_section.do_fill_in("TITLE", "First section")
form_edit_section.do_form_submit()
- section: Section = screen_document.get_section(2)
+ section: Requirement = screen_document.get_node(3)
- section.assert_section_title("First section")
+ section.assert_requirement_title("First section")
screen_document.assert_toc_contains("First section")
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/expected_output/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/expected_output/document.sdoc
index 301e83d36..1a38e08be 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/expected_output/document.sdoc
@@ -6,15 +6,15 @@ STATEMENT: >>>
Hello world!
<<<
-[SECTION]
+[[SECTION]]
TITLE: Section Foobar
-[/SECTION]
+[[/SECTION]]
-[SECTION]
+[[SECTION]]
TITLE: Section created by this test
-[/SECTION]
+[[/SECTION]]
[DOCUMENT_FROM_FILE]
FILE: fragment.sdoc
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/expected_output/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/input/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/input/document.sdoc
index b0115f9de..531bdff45 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/input/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/input/document.sdoc
@@ -6,10 +6,10 @@ STATEMENT: >>>
Hello world!
<<<
-[SECTION]
+[[SECTION]]
TITLE: Section Foobar
-[/SECTION]
+[[/SECTION]]
[DOCUMENT_FROM_FILE]
FILE: fragment.sdoc
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/input/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/test_case.py b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/test_case.py
index dc94267b8..666c57a09 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_above_but_below_another_section/test_case.py
@@ -1,9 +1,10 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
from tests.end2end.helpers.components.node.add_node_menu import AddNode_Menu
+from tests.end2end.helpers.components.node.requirement import Requirement
from tests.end2end.helpers.components.node.section import Section
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -32,19 +33,21 @@ def test(self):
screen_document.assert_text("Hello world!")
- section: Section = screen_document.get_section(node_order=2)
+ section: Section = screen_document.get_section(node_order=1)
section_menu: AddNode_Menu = section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- section_menu.do_node_add_section_above()
+ form_edit_section: Form_EditRequirement = (
+ section_menu.do_node_add_element_above("SECTION")
)
- form_edit_section.do_fill_in_title("Section created by this test")
+ form_edit_section.do_fill_in(
+ "TITLE", "Section created by this test"
+ )
form_edit_section.do_form_submit()
- section: Section = screen_document.get_section(2)
+ section: Requirement = screen_document.get_node(3)
- section.assert_section_title("Section created by this test")
+ section.assert_requirement_title("Section created by this test")
screen_document.assert_toc_contains("Section created by this test")
@@ -56,7 +59,7 @@ def test(self):
# A basic extra test that ensures that the section has a right
# document parent (encountered this regression during implementation).
#
- form_edit_section = section.do_open_form_edit_section()
+ form_edit_section = section.do_open_form_edit_requirement()
form_edit_section.do_form_submit()
screen_document.assert_toc_contains("Section Foobar")
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/expected_output/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/expected_output/document.sdoc
index 13adb8985..77308df0a 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/expected_output/document.sdoc
@@ -9,7 +9,7 @@ Hello world!
[DOCUMENT_FROM_FILE]
FILE: fragment.sdoc
-[SECTION]
+[[SECTION]]
TITLE: First section
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/expected_output/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/input/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/test_case.py b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/test_case.py
index 898f8c7c1..97c14d9b1 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/_outside_fragment/update_included_document_create_section_below/test_case.py
@@ -1,9 +1,10 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
from tests.end2end.helpers.components.node.add_node_menu import AddNode_Menu
+from tests.end2end.helpers.components.node.requirement import Requirement
from tests.end2end.helpers.components.node.section import Section
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -35,16 +36,16 @@ def test(self):
section: Section = screen_document.get_section(node_order=1)
section_menu: AddNode_Menu = section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- section_menu.do_node_add_section_below()
+ form_edit_section: Form_EditRequirement = (
+ section_menu.do_node_add_element_below("SECTION")
)
- form_edit_section.do_fill_in_title("First section")
+ form_edit_section.do_fill_in("TITLE", "First section")
form_edit_section.do_form_submit()
- section: Section = screen_document.get_section(2)
+ section: Requirement = screen_document.get_node(2)
- section.assert_section_title("First section")
+ section.assert_requirement_title("First section")
screen_document.assert_toc_contains("First section")
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/expected_output/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/expected_output/document.sdoc
similarity index 86%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/expected_output/document.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/expected_output/document.sdoc
index 288e83b9a..905aa4722 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/expected_output/document.sdoc
@@ -6,10 +6,10 @@ STATEMENT: >>>
Hello world!
<<<
-[SECTION]
+[[SECTION]]
TITLE: Section that nests a document fragment.
[DOCUMENT_FROM_FILE]
FILE: fragment.sdoc
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/expected_output/fragment.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/expected_output/fragment.sdoc
similarity index 59%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/expected_output/fragment.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/expected_output/fragment.sdoc
index b668fc9e6..ea6620c78 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/expected_output/fragment.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/expected_output/fragment.sdoc
@@ -1,12 +1,12 @@
[DOCUMENT]
TITLE: Fragment
-[SECTION]
+[[SECTION]]
TITLE: First section
-[SECTION]
+[[SECTION]]
TITLE: Second section
-[/SECTION]
+[[/SECTION]]
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/input/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/input/document.sdoc
similarity index 86%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/input/document.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/input/document.sdoc
index 288e83b9a..905aa4722 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/input/document.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/input/document.sdoc
@@ -6,10 +6,10 @@ STATEMENT: >>>
Hello world!
<<<
-[SECTION]
+[[SECTION]]
TITLE: Section that nests a document fragment.
[DOCUMENT_FROM_FILE]
FILE: fragment.sdoc
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/input/fragment.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/input/fragment.sdoc
similarity index 66%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/input/fragment.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/input/fragment.sdoc
index 64437acb9..71e19faf6 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/input/fragment.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/input/fragment.sdoc
@@ -1,7 +1,7 @@
[DOCUMENT]
TITLE: Fragment
-[SECTION]
+[[SECTION]]
TITLE: First section
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/test_case.py b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/test_case.py
similarity index 71%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/test_case.py
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/test_case.py
index 0179a3881..61155d65a 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section_2/test_case.py
@@ -1,9 +1,9 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
from tests.end2end.helpers.components.node.add_node_menu import AddNode_Menu
-from tests.end2end.helpers.components.node.section import Section
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.components.node.requirement import Requirement
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -32,19 +32,19 @@ def test(self):
screen_document.assert_text("Hello world!")
- section: Section = screen_document.get_section(node_order=3)
+ section: Requirement = screen_document.get_node(node_order=3)
section_menu: AddNode_Menu = section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- section_menu.do_node_add_section_child()
+ form_edit_section: Form_EditRequirement = (
+ section_menu.do_node_add_element_child("SECTION")
)
- form_edit_section.do_fill_in_title("Second section")
+ form_edit_section.do_fill_in("TITLE", "Second section")
form_edit_section.do_form_submit()
- section: Section = screen_document.get_section(4)
+ section: Requirement = screen_document.get_node(4)
- section.assert_section_title("Second section")
+ section.assert_requirement_title("Second section")
screen_document.assert_toc_contains("Second section")
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/expected_output/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/document.sdoc
similarity index 100%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/expected_output/document.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/document.sdoc
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/expected_output/fragment.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/fragment.sdoc
similarity index 59%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/expected_output/fragment.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/fragment.sdoc
index b668fc9e6..ea6620c78 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document__fragment_nested_in_section__create_section/expected_output/fragment.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/fragment.sdoc
@@ -1,12 +1,12 @@
[DOCUMENT]
TITLE: Fragment
-[SECTION]
+[[SECTION]]
TITLE: First section
-[SECTION]
+[[SECTION]]
TITLE: Second section
-[/SECTION]
+[[/SECTION]]
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/input/document.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/document.sdoc
similarity index 100%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/input/document.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/document.sdoc
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/input/fragment.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/fragment.sdoc
similarity index 66%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/input/fragment.sdoc
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/fragment.sdoc
index 64437acb9..71e19faf6 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/input/fragment.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/fragment.sdoc
@@ -1,7 +1,7 @@
[DOCUMENT]
TITLE: Fragment
-[SECTION]
+[[SECTION]]
TITLE: First section
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/test_case.py b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/test_case.py
similarity index 71%
rename from tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/test_case.py
rename to tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/test_case.py
index ef4db46b1..a0a0439a9 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_section/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_child_section/test_case.py
@@ -1,9 +1,9 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
from tests.end2end.helpers.components.node.add_node_menu import AddNode_Menu
-from tests.end2end.helpers.components.node.section import Section
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.components.node.requirement import Requirement
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -32,19 +32,19 @@ def test(self):
screen_document.assert_text("Hello world!")
- section: Section = screen_document.get_section(node_order=2)
+ section: Requirement = screen_document.get_node(node_order=2)
section_menu: AddNode_Menu = section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- section_menu.do_node_add_section_child()
+ form_edit_section: Form_EditRequirement = (
+ section_menu.do_node_add_element_child("SECTION")
)
- form_edit_section.do_fill_in_title("Second section")
+ form_edit_section.do_fill_in("TITLE", "Second section")
form_edit_section.do_form_submit()
- section: Section = screen_document.get_section(3)
+ section: Requirement = screen_document.get_node(3)
- section.assert_section_title("Second section")
+ section.assert_requirement_title("Second section")
screen_document.assert_toc_contains("Second section")
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/expected_output/fragment.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/expected_output/fragment.sdoc
index 64437acb9..71e19faf6 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/expected_output/fragment.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/expected_output/fragment.sdoc
@@ -1,7 +1,7 @@
[DOCUMENT]
TITLE: Fragment
-[SECTION]
+[[SECTION]]
TITLE: First section
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/expected_output/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/input/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/test_case.py b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/test_case.py
index 481e599ef..25a3911cc 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_create_first_child_section/test_case.py
@@ -1,9 +1,10 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
from tests.end2end.helpers.components.node.add_node_menu import AddNode_Menu
+from tests.end2end.helpers.components.node.requirement import Requirement
from tests.end2end.helpers.components.node.section import Section
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -35,16 +36,17 @@ def test(self):
section: Section = screen_document.get_section(node_order=1)
section_menu: AddNode_Menu = section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- section_menu.do_node_add_section_child()
+
+ form_edit_section: Form_EditRequirement = (
+ section_menu.do_node_add_element_child("SECTION")
)
- form_edit_section.do_fill_in_title("First section")
+ form_edit_section.do_fill_in("TITLE", "First section")
form_edit_section.do_form_submit()
- section: Section = screen_document.get_section(2)
+ section: Requirement = screen_document.get_node(2)
- section.assert_section_title("First section")
+ section.assert_requirement_title("First section")
screen_document.assert_toc_contains("First section")
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/expected_output/fragment.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/expected_output/fragment.sdoc
index c2469b928..de637387e 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/expected_output/fragment.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/expected_output/fragment.sdoc
@@ -1,8 +1,8 @@
[DOCUMENT]
TITLE: Fragment
-[SECTION]
+[[SECTION]]
UID: SECTION-UID
TITLE: Modified title
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/expected_output/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/input/fragment.sdoc b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/input/fragment.sdoc
index 64437acb9..71e19faf6 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/input/fragment.sdoc
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/input/fragment.sdoc
@@ -1,7 +1,7 @@
[DOCUMENT]
TITLE: Fragment
-[SECTION]
+[[SECTION]]
TITLE: First section
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/input/strictdoc.toml b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/test_case.py b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/test_case.py
index bd1bcbe70..48a31c12c 100644
--- a/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/test_case.py
+++ b/tests/end2end/screens/document/_cross_cutting/included_documents/update_included_document_edit_section/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -28,16 +28,16 @@ def test(self):
screen_document.assert_on_screen_document()
screen_document.assert_header_document_title("Document 1")
- section = screen_document.get_section(2)
+ section = screen_document.get_node(1)
- form_edit_section: Form_EditSection = (
- section.do_open_form_edit_section()
+ form_edit_section: Form_EditRequirement = (
+ section.do_open_form_edit_requirement()
)
- form_edit_section.do_fill_in_uid("SECTION-UID")
- form_edit_section.do_fill_in_title("Modified title")
+ form_edit_section.do_fill_in("UID", "SECTION-UID")
+ form_edit_section.do_fill_in("TITLE", "Modified title")
form_edit_section.do_form_submit()
- section.assert_section_title("Modified title", "1")
+ section.assert_requirement_title("Modified title", "1")
screen_document.assert_toc_contains("Modified title")
assert test_setup.compare_sandbox_and_expected_output()
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/expected_output/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/input/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/test_case.py b/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/test_case.py
index 6bddb1a86..0a8c505e4 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/test_case.py
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_must_validate_empty_name/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -30,13 +30,15 @@ def test(self):
root_node = screen_document.get_root_node()
root_node_menu = root_node.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- root_node_menu.do_node_add_section_first()
+ form_edit_section: Form_EditRequirement = (
+ root_node_menu.do_node_add_element_first("SECTION")
)
- form_edit_section.do_fill_in_title("")
+ form_edit_section.do_fill_in("TITLE", "")
form_edit_section.do_form_submit_and_catch_error(
- "Section title must not be empty."
+ "Node's TITLE must not be empty. "
+ "If there is no appropriate value for this field yet, "
+ "enter TBD (to be done) or TBC (to be confirmed)."
)
assert test_setup.compare_sandbox_and_expected_output()
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/expected_output/document.sdoc b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/expected_output/document.sdoc
index 845e01c91..8f575d6d0 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/expected_output/document.sdoc
@@ -1,8 +1,8 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
UID: SECTION-UID
TITLE: Section 1
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/expected_output/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/input/document.sdoc b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/input/document.sdoc
index 845e01c91..8f575d6d0 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/input/document.sdoc
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/input/document.sdoc
@@ -1,8 +1,8 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
UID: SECTION-UID
TITLE: Section 1
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/input/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/test_case.py b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/test_case.py
index bc74d8624..f5c0d2387 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/test_case.py
+++ b/tests/end2end/screens/document/create_section/_validations/create_section_with_nonunique_uid/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -28,20 +28,20 @@ def test(self):
screen_document.assert_on_screen_document()
screen_document.assert_header_document_title("Document 1")
- existing_section = screen_document.get_section()
+ existing_section = screen_document.get_node()
existing_section_menu = existing_section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- existing_section_menu.do_node_add_section_below()
+ form_edit_section: Form_EditRequirement = (
+ existing_section_menu.do_node_add_element_below("SECTION")
)
- form_edit_section.do_fill_in_title("Section 2")
- form_edit_section.do_fill_in_uid("SECTION-UID")
+ form_edit_section.do_fill_in("TITLE", "Section 2")
+ form_edit_section.do_fill_in("UID", "SECTION-UID")
form_edit_section.do_form_submit_and_catch_error(
"The chosen UID must be unique. "
- "There is another section 'Section 1' with a UID 'SECTION-UID'."
+ "Another node with this UID already exists: 'SECTION-UID'."
)
assert test_setup.compare_sandbox_and_expected_output()
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/expected_output/document.sdoc b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/expected_output/document.sdoc
index 813c4a38a..1353a3e6e 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/expected_output/document.sdoc
@@ -1,8 +1,8 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
UID: SAME-UID
TITLE: Section 1
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/expected_output/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/input/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/test_case.py b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/test_case.py
index f687e2862..d22c1086d 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/test_case.py
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_section_with_same_uid/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -32,26 +32,26 @@ def test(self):
root_node_menu = root_node.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- root_node_menu.do_node_add_section_first()
+ form_edit_section: Form_EditRequirement = (
+ root_node_menu.do_node_add_element_first("SECTION")
)
- form_edit_section.do_fill_in_title("Section 1")
- form_edit_section.do_fill_in_uid("SAME-UID")
+ form_edit_section.do_fill_in("TITLE", "Section 1")
+ form_edit_section.do_fill_in("UID", "SAME-UID")
form_edit_section.do_form_submit()
- created_section = screen_document.get_section()
+ created_section = screen_document.get_node()
created_section_menu = created_section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- created_section_menu.do_node_add_section_below()
+ form_edit_section: Form_EditRequirement = (
+ created_section_menu.do_node_add_element_below("SECTION")
)
- form_edit_section.do_fill_in_title("Section 2")
- form_edit_section.do_fill_in_uid("SAME-UID")
+ form_edit_section.do_fill_in("TITLE", "Section 2")
+ form_edit_section.do_fill_in("UID", "SAME-UID")
form_edit_section.do_form_submit_and_catch_error(
"The chosen UID must be unique. "
- "There is another section 'Section 1' with a UID 'SAME-UID'."
+ "Another node with this UID already exists: 'SAME-UID'."
)
assert test_setup.compare_sandbox_and_expected_output()
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/expected_output/document.sdoc b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/expected_output/document.sdoc
index 84da74a6a..3192e4f81 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/expected_output/document.sdoc
@@ -1,13 +1,13 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
UID: SAME-UID
TITLE: Section 1
-[/SECTION]
+[[/SECTION]]
-[SECTION]
+[[SECTION]]
TITLE: Section 2
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/expected_output/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/input/strictdoc.toml b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/test_case.py b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/test_case.py
index 629ee4256..8aa1d2f93 100644
--- a/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/test_case.py
+++ b/tests/end2end/screens/document/create_section/_validations/create_two_sections_then_update_with_same_uid/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -32,31 +32,31 @@ def test(self):
root_node_menu = root_node.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- root_node_menu.do_node_add_section_first()
+ form_edit_section: Form_EditRequirement = (
+ root_node_menu.do_node_add_element_first("SECTION")
)
- form_edit_section.do_fill_in_title("Section 1")
- form_edit_section.do_fill_in_uid("SAME-UID")
+ form_edit_section.do_fill_in("TITLE", "Section 1")
+ form_edit_section.do_fill_in("UID", "SAME-UID")
form_edit_section.do_form_submit()
- created_section = screen_document.get_section()
+ created_section = screen_document.get_node()
created_section_menu = created_section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- created_section_menu.do_node_add_section_below()
+ form_edit_section: Form_EditRequirement = (
+ created_section_menu.do_node_add_element_below("SECTION")
)
- form_edit_section.do_fill_in_title("Section 2")
+ form_edit_section.do_fill_in("TITLE", "Section 2")
form_edit_section.do_form_submit()
- created_section = screen_document.get_section(node_order=2)
- form_edit_section: Form_EditSection = (
- created_section.do_open_form_edit_section()
+ created_section = screen_document.get_node(node_order=2)
+ form_edit_section: Form_EditRequirement = (
+ created_section.do_open_form_edit_requirement()
)
- form_edit_section.do_fill_in_uid("SAME-UID")
+ form_edit_section.do_fill_in("UID", "SAME-UID")
form_edit_section.do_form_submit_and_catch_error(
- "UID uniqueness validation error: "
- "There is already an existing node with this UID: 1. Section 1."
+ "The chosen UID must be unique. "
+ "Another node with this UID already exists: 'SAME-UID'."
)
assert test_setup.compare_sandbox_and_expected_output()
diff --git a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/expected_output/document.sdoc b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/expected_output/document.sdoc
index bcab0f46d..7b42acccd 100644
--- a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/expected_output/document.sdoc
@@ -1,7 +1,7 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
TITLE: Section B
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/expected_output/strictdoc.toml b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/input/document.sdoc b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/input/document.sdoc
index bcab0f46d..7b42acccd 100644
--- a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/input/document.sdoc
+++ b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/input/document.sdoc
@@ -1,7 +1,7 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
TITLE: Section B
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/input/strictdoc.toml b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/test_case.py b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/test_case.py
index 5efc52c86..ae2463b8c 100644
--- a/tests/end2end/screens/document/create_section/create_section_cancel_new_section/test_case.py
+++ b/tests/end2end/screens/document/create_section/create_section_cancel_new_section/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -28,11 +28,11 @@ def test(self):
screen_document.assert_on_screen_document()
screen_document.assert_header_document_title("Document 1")
- section = screen_document.get_section()
+ section = screen_document.get_node()
section_menu = section.do_open_node_menu()
- form_edit_section: Form_EditSection = (
- section_menu.do_node_add_section_above()
+ form_edit_section: Form_EditRequirement = (
+ section_menu.do_node_add_element_above("SECTION")
)
form_edit_section.do_form_cancel()
diff --git a/tests/end2end/screens/document/create_section/create_section_three_nested_sections/expected_output/document.sdoc b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/expected_output/document.sdoc
index 60b52aae9..23ac07731 100644
--- a/tests/end2end/screens/document/create_section/create_section_three_nested_sections/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/expected_output/document.sdoc
@@ -1,17 +1,17 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
TITLE: Section_1
-[SECTION]
+[[SECTION]]
TITLE: Section_1_1
-[SECTION]
+[[SECTION]]
TITLE: Section_1_1_1
-[/SECTION]
+[[/SECTION]]
-[/SECTION]
+[[/SECTION]]
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/create_section_three_nested_sections/expected_output/strictdoc.toml b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/create_section_three_nested_sections/input/strictdoc.toml b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/create_section_three_nested_sections/test_case.py b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/test_case.py
index d4a4f0968..7a2989211 100644
--- a/tests/end2end/screens/document/create_section/create_section_three_nested_sections/test_case.py
+++ b/tests/end2end/screens/document/create_section/create_section_three_nested_sections/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -32,42 +32,42 @@ def test(self):
root_node = screen_document.get_root_node()
root_node_menu = root_node.do_open_node_menu()
- form_edit_section_1: Form_EditSection = (
- root_node_menu.do_node_add_section_first()
+ form_edit_section_1: Form_EditRequirement = (
+ root_node_menu.do_node_add_element_first("SECTION")
)
- form_edit_section_1.do_fill_in_title("Section_1")
+ form_edit_section_1.do_fill_in("TITLE", "Section_1")
form_edit_section_1.do_form_submit()
- section_1 = screen_document.get_section()
- section_1.assert_section_title("Section_1", "1")
+ section_1 = screen_document.get_node()
+ section_1.assert_requirement_title("Section_1", "1")
screen_document.assert_toc_contains("Section_1")
# Section 1_1 as child
section_1_node_menu = section_1.do_open_node_menu()
- form_edit_section_2: Form_EditSection = (
- section_1_node_menu.do_node_add_section_child()
+ form_edit_section_2: Form_EditRequirement = (
+ section_1_node_menu.do_node_add_element_child("SECTION")
)
- form_edit_section_2.do_fill_in_title("Section_1_1")
+ form_edit_section_2.do_fill_in("TITLE", "Section_1_1")
form_edit_section_2.do_form_submit()
- section_2 = screen_document.get_section(2)
- section_2.assert_section_title("Section_1_1", "1.1")
+ section_2 = screen_document.get_node(2)
+ section_2.assert_requirement_title("Section_1_1", "1.1")
screen_document.assert_toc_contains("Section_1_1")
# # Section 1_1_1 as child
section_2_node_menu = section_2.do_open_node_menu()
- form_edit_section_3: Form_EditSection = (
- section_2_node_menu.do_node_add_section_child()
+ form_edit_section_3: Form_EditRequirement = (
+ section_2_node_menu.do_node_add_element_child("SECTION")
)
- form_edit_section_3.do_fill_in_title("Section_1_1_1")
+ form_edit_section_3.do_fill_in("TITLE", "Section_1_1_1")
form_edit_section_3.do_form_submit()
- section_3 = screen_document.get_section(3)
- section_3.assert_section_title("Section_1_1_1", "1.1.1")
+ section_3 = screen_document.get_node(3)
+ section_3.assert_requirement_title("Section_1_1_1", "1.1.1")
screen_document.assert_toc_contains("Section_1_1_1")
assert test_setup.compare_sandbox_and_expected_output()
diff --git a/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/expected_output/document.sdoc b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/expected_output/document.sdoc
index 0827117de..ac93b919e 100644
--- a/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/expected_output/document.sdoc
@@ -1,12 +1,12 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
TITLE: First title
-[/SECTION]
+[[/SECTION]]
-[SECTION]
+[[SECTION]]
TITLE: Second title
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/expected_output/strictdoc.toml b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/input/strictdoc.toml b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/test_case.py b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/test_case.py
index bd39a78bc..66f827a2b 100644
--- a/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/test_case.py
+++ b/tests/end2end/screens/document/create_section/create_section_two_sibling_sections/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -35,16 +35,16 @@ def test(self):
root_node = screen_document.get_root_node()
root_node_menu = root_node.do_open_node_menu()
- form_edit_section_1: Form_EditSection = (
- root_node_menu.do_node_add_section_first()
+ form_edit_section_1: Form_EditRequirement = (
+ root_node_menu.do_node_add_element_first("SECTION")
)
- form_edit_section_1.do_fill_in_title("First title")
+ form_edit_section_1.do_fill_in("TITLE", "First title")
form_edit_section_1.do_form_submit()
- section_1 = screen_document.get_section()
+ section_1 = screen_document.get_node(1)
- section_1.assert_section_title("First title", "1")
+ section_1.assert_requirement_title("First title", "1")
screen_document.assert_toc_contains("First title")
#
@@ -53,15 +53,15 @@ def test(self):
section_1_node_menu = section_1.do_open_node_menu()
- form_edit_section2: Form_EditSection = (
- section_1_node_menu.do_node_add_section_below()
+ form_edit_section2: Form_EditRequirement = (
+ section_1_node_menu.do_node_add_element_below("SECTION")
)
- form_edit_section2.do_fill_in_title("Second title")
+ form_edit_section2.do_fill_in("TITLE", "Second title")
form_edit_section2.do_form_submit()
- section2 = screen_document.get_section(2)
+ section2 = screen_document.get_node(2)
- section2.assert_section_title("Second title", "2")
+ section2.assert_requirement_title("Second title", "2")
screen_document.assert_toc_contains("Second title")
assert test_setup.compare_sandbox_and_expected_output()
diff --git a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/expected_output/document.sdoc b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/expected_output/document.sdoc
index 9178cdfac..81c0fcea0 100644
--- a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/expected_output/document.sdoc
+++ b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/expected_output/document.sdoc
@@ -1,13 +1,13 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
UID: DUPLICATE_UID
TITLE: First section
-[/SECTION]
+[[/SECTION]]
-[SECTION]
+[[SECTION]]
TITLE: Second section
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/expected_output/strictdoc.toml b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/expected_output/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/expected_output/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/input/document.sdoc b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/input/document.sdoc
index 86b710fe4..dbcb43fa3 100644
--- a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/input/document.sdoc
+++ b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/input/document.sdoc
@@ -1,12 +1,12 @@
[DOCUMENT]
TITLE: Document 1
-[SECTION]
+[[SECTION]]
TITLE: First section
-[/SECTION]
+[[/SECTION]]
-[SECTION]
+[[SECTION]]
TITLE: Second section
-[/SECTION]
+[[/SECTION]]
diff --git a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/input/strictdoc.toml b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/input/strictdoc.toml
new file mode 100644
index 000000000..190f5866a
--- /dev/null
+++ b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/input/strictdoc.toml
@@ -0,0 +1,3 @@
+[project]
+
+section_behavior = "[[SECTION]]"
diff --git a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/test_case.py b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/test_case.py
index aad0ecce0..541eeb21b 100644
--- a/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/test_case.py
+++ b/tests/end2end/screens/document/update_section/_validation/update_section_create_two_duplicate_uids/test_case.py
@@ -1,7 +1,7 @@
from tests.end2end.e2e_case import E2ECase
from tests.end2end.end2end_test_setup import End2EndTestSetup
-from tests.end2end.helpers.screens.document.form_edit_section import (
- Form_EditSection,
+from tests.end2end.helpers.screens.document.form_edit_requirement import (
+ Form_EditRequirement,
)
from tests.end2end.helpers.screens.project_index.screen_project_index import (
Screen_ProjectIndex,
@@ -28,21 +28,21 @@ def test(self):
screen_document.assert_on_screen_document()
screen_document.assert_header_document_title("Document 1")
- section = screen_document.get_section()
- form_edit_section: Form_EditSection = (
- section.do_open_form_edit_section()
+ section = screen_document.get_node(1)
+ form_edit_section: Form_EditRequirement = (
+ section.do_open_form_edit_requirement()
)
- form_edit_section.do_fill_in_uid("DUPLICATE_UID")
+ form_edit_section.do_fill_in("UID", "DUPLICATE_UID")
form_edit_section.do_form_submit()
- section = screen_document.get_section(node_order=2)
- form_edit_section: Form_EditSection = (
- section.do_open_form_edit_section()
+ section = screen_document.get_node(2)
+ form_edit_section: Form_EditRequirement = (
+ section.do_open_form_edit_requirement()
)
- form_edit_section.do_fill_in_uid("DUPLICATE_UID")
+ form_edit_section.do_fill_in("UID", "DUPLICATE_UID")
form_edit_section.do_form_submit_and_catch_error(
- "UID uniqueness validation error: "
- "There is already an existing node with this UID: 1. First section."
+ "The chosen UID must be unique. "
+ "Another node with this UID already exists: 'DUPLICATE_UID'."
)
assert test_setup.compare_sandbox_and_expected_output()