diff --git a/core/ui/TestCases/DefaultTemplate.tid b/core/ui/TestCases/DefaultTemplate.tid index 04623cbc6..39c6bab52 100644 --- a/core/ui/TestCases/DefaultTemplate.tid +++ b/core/ui/TestCases/DefaultTemplate.tid @@ -2,91 +2,141 @@ title: $:/core/ui/testcases/DefaultTemplate code-body: yes \whitespace trim + +\function tf.state() [] + \procedure linkcatcherActions() <%if [has[title]] %> - <$qualify title=<> name="qualifiedState"> - <$action-setfield $tiddler=<> text=<>/> - + <$action-setfield $tiddler=<> text=<>/> <%endif%> \end -<$let - state={{{ [] }}} -> -
-
-

- <$genesis $type={{{ [!match[]then[$link]else[span]] }}} to=<>> - <%if [!match[]] %> - !match[fail]then[tc-test-case-result-icon-pass]] [match[fail]then[tc-test-case-result-icon-fail]] +[join[ ]] }}}> - <%if [!match[fail]] %> - {{$:/core/images/done-button}} - <%else%> - {{$:/core/images/close-button}} - <%endif%> - +\procedure testcase-header() +
+

+ <$genesis $type={{{ [!match[]then[$link]else[span]] }}} to=<>> + <%if [!match[]] %> + !match[fail]then[tc-test-case-result-icon-pass]] + [match[fail]then[tc-test-case-result-icon-fail]] + +[join[ ]] }}} + > + <%if [!match[fail]] %> + {{$:/core/images/done-button}} + <%else%> + {{$:/core/images/close-button}} <%endif%> - <$view tiddler="Description" mode="inline"/> - - - <$button popup=`$(state)$-more` - tooltip={{$:/language/Buttons/More/Hint}} - aria-label={{$:/language/Buttons/More/Caption}} - class="tc-btn-invisible" - selectedClass="tc-selected" - > - {{$:/core/images/down-arrow}} - - <$let - tv-config-toolbar-icons="yes" - tv-config-toolbar-text="yes" - tv-config-toolbar-class="tc-btn-invisible" - > - <$reveal state=`$(state)$-more` type="popup" position="belowleft" animate="yes"> -
- <$list filter="[all[shadows+tiddlers]tag[$:/tags/TestCase/Actions]!has[draft.of]]" - variable="listItem" - > - <$transclude $tiddler=<> $mode="inline"/> - -
- -
-

+ <%endif%> + <$view tiddler="Description" mode="inline"/> + + + <> + +

+
+\end + +\procedure testcase-toolbar() +<$button popup=`$(tf.state)$-more` + tooltip={{$:/language/Buttons/More/Hint}} + aria-label={{$:/language/Buttons/More/Caption}} + class="tc-btn-invisible" + selectedClass="tc-selected" +> + {{$:/core/images/down-arrow}} + +<$let + tv-config-toolbar-icons="yes" + tv-config-toolbar-text="yes" + tv-config-toolbar-class="tc-btn-invisible" +> + <$reveal state=`$(tf.state)$-more` type="popup" position="belowleft" animate="yes"> +
+ <$list filter="[all[shadows+tiddlers]tag[$:/tags/TestCase/Actions]!has[draft.of]]" + variable="listItem" + > + <$transclude $tiddler=<> $mode="inline"/> +
- <%if [[Narrative]is[tiddler]] %> -
- <$transclude $tiddler="Narrative" $mode="block"/> -
- <%endif%> - <%if [match[fail]] %> -
-
- TEST FAILED -
-
- <$diff-text source=<> dest=<>/> -
-
- <%endif%> -
-
- <$macrocall $name="tabs" tabsList="[all[tiddlers]sort[]] -[prefix] -Description -Narrative -Output Output +[putfirst[]] -[has[plugin-type]]" state=<> default="Output" template="$:/core/ui/testcases/DefaultTemplate/SourceTabs"/> -
-
-
-
- <%if [!match[]else[wikitext]match[plaintext]] %> -
<$view tiddler="Output" format="plainwikified" mode="block"/>
- <%else%> - <$linkcatcher actions=<>> - <$tiddler tiddler="Output"> - <$transclude $tiddler="Output" $mode="block"/> - - - <%endif%> -
-
-
+ +\end + +\procedure testcase-narrative() +
+ <$transclude $tiddler="Narrative" $mode="block"/> +
+\end + +\procedure testcase-fail() +
+
+ TEST FAILED +
+
+ <$diff-text source=<> dest=<>/> +
+
+\end + +\procedure testcase-output-wikified() +<$linkcatcher actions=<>> + <$tiddler tiddler="Output"> + <$transclude $tiddler="Output" $mode="block"/> + + +\end + +\procedure testcase-output() +
+ <%if [!match[]else[wikitext]match[plaintext]] %> +
<$view tiddler="Output" format="plainwikified" mode="block"/>
+ <%else%> + <> + <%endif%> +
+\end + +\procedure testcase-tabsList() +[all[tiddlers]sort[]] Output +[putfirst[]] +-Description +-Narrative +-[has[plugin-type]] +-[prefix] +-[prefix[$:/state/popup/export]] +\end + +\procedure testcase-source() +
+ <$macrocall $name="tabs" + tabsList=<> + explicitState=<> + default="Output" + template="$:/core/ui/testcases/DefaultTemplate/SourceTabs" + /> +
+\end + +\procedure testcase-panes() +
+ <> +
+ <> +
+\end + +\procedure testcase-body() +
+ <> + <%if [[Narrative]is[tiddler]] %> + <> + <%endif%> + <%if [match[fail]] %> + <> + <%endif%> + <> +
+\end + +<> \ No newline at end of file diff --git a/core/ui/TestCases/actions/Export.tid b/core/ui/TestCases/actions/Export.tid index 0d5f976e5..79c6eb93a 100644 --- a/core/ui/TestCases/actions/Export.tid +++ b/core/ui/TestCases/actions/Export.tid @@ -1,4 +1,4 @@ title: $:/core/ui/testcases/actions/Export tags: $:/tags/TestCase/Actions -<$macrocall $name="exportButton" exportFilter="[all[tiddlers]sort[]] -[prefix[$:/state/]] -Description -Narrative -ExpectedResult -Output Output +[putfirst[]] -[has[plugin-type]]" lingoBase="$:/language/Buttons/ExportTiddlers/"/> \ No newline at end of file +<$macrocall $name="exportButton" exportFilter="[all[tiddlers]sort[]] -[prefix[$:/state/]] -Description -Narrative -ExpectedResult -[has[plugin-type]]" lingoBase="$:/language/Buttons/ExportTiddlers/"/> \ No newline at end of file