Path:
tests/integration/features/source_code_traceability/_language_parsers/robot/06_robot_source_nodes/test.itest
Lines:
42
Non-empty lines:
38
Non-empty lines covered with requirements:
38 / 38 (100.0%)
Functions:
0
Functions covered by requirements:
0 / 0 (0.0%)
- "7.7.1. Parse nodes from source code" (REQUIREMENT)
- "7.2.5. Language-aware parsing of Robot framework code" (REQUIREMENT)
1
# @relation(SDOC-SRS-141, SDOC-SRS-148, scope=file)
2
#
3
# Source nodes from Robot Framework [Documentation] sections.
4
#
5
# StrictDoc parses key-value pairs from [Documentation] and generates source
6
# nodes of type TEST_SPEC into testcases.sdoc. @relation markers in the
7
# robot file link test case to requirements. @relation markers in the
8
# markdown test report link test results to test cases.
9
10
RUN: %strictdoc export %S --output-dir %T | filecheck %s --dump-input=fail
11
CHECK: Published: Hello world doc
12
13
RUN: %check_exists --file "%T/html/_source_files/tests/file.robot.html"
14
15
# Check testcases.sdoc contains generated source nodes with field values and
16
# links back to the robot source file and the markdown test session report.
17
RUN: %cat %T/html/%THIS_TEST_FOLDER/testcases.html | filecheck %s --check-prefix CHECK-SPEC
18
CHECK-SPEC: TC-AUTH-001
19
CHECK-SPEC: <a{{.*}}href="../_source_files/test_sessions/2026_05_28.md.html#TC-AUTH-001#9#10">20
CHECK-SPEC: test_sessions/2026_05_28.md, <i>lines: 9-10</i>
21
CHECK-SPEC: TestExecution
22
CHECK-SPEC: INTENTION:
23
CHECK-SPEC: Verify that valid credentials grant access.
24
CHECK-SPEC: EXPECTED_RESULTS:
25
CHECK-SPEC: TC-AUTH-002
26
CHECK-SPEC: <a{{.*}}href="../_source_files/test_sessions/2026_05_28.md.html#TC-AUTH-002#9#10">27
CHECK-SPEC: test_sessions/2026_05_28.md, <i>lines: 9-10</i>
28
CHECK-SPEC: TestExecution
29
CHECK-SPEC: INTENTION:
30
CHECK-SPEC: Verify that login fails with wrong password
31
CHECK-SPEC: EXPECTED_RESULTS:
32
33
# Check requirements contain links to TestCase in robot DSL.
34
RUN: %cat %T/html/%THIS_TEST_FOLDER/input.html | filecheck %s --check-prefix CHECK-HTML
35
CHECK-HTML: REQ-AUTH-001
36
CHECK-HTML: TC-AUTH-001
37
CHECK-HTML: <a{{.*}}href="../_source_files/tests/file.robot.html#REQ-AUTH-001#2#10">38
CHECK-HTML: tests/file.robot, <i>lines: 2-10</i>
39
CHECK-HTML: REQ-AUTH-002
40
CHECK-HTML: TC-AUTH-002
41
CHECK-HTML: <a{{.*}}href="../_source_files/tests/file.robot.html#REQ-AUTH-002#12#20">42
CHECK-HTML: tests/file.robot, <i>lines: 12-20</i>