Add tc-test-case class to testcase-widget (#8744)

* add tc-tesc-case class to testcase-widget

* add default and custom class to testcase-widget

* Testcase widget update tests for default and custom class definitions
This commit is contained in:
Mario Pietsch
2024-12-05 13:33:27 +01:00
committed by GitHub
parent c7f741d4f8
commit 42b2b9fd20
7 changed files with 10 additions and 7 deletions

View File

@@ -24,4 +24,4 @@ This is a payload tiddler from a compound tiddler
+
title: ExpectedResult
<p><div><div>[{"title":"Payload Tiddler","tags":"Alpha Beta Gamma","text":"This is a payload tiddler from a compound tiddler","custom":"Alpha"}]</div></div></p>
<p><div class="tc-test-case "><div>[{"title":"Payload Tiddler","tags":"Alpha Beta Gamma","text":"This is a payload tiddler from a compound tiddler","custom":"Alpha"}]</div></div></p>

View File

@@ -20,4 +20,4 @@ This is the tiddler HelloThere
+
title: ExpectedResult
<p><div><div>[{"title":"RealTitle","tags":"Definitions","text":"This is the tiddler HelloThere"}]</div></div></p>
<p><div class="tc-test-case "><div>[{"title":"RealTitle","tags":"Definitions","text":"This is the tiddler HelloThere"}]</div></div></p>

View File

@@ -25,4 +25,4 @@ This is the tiddler AnotherDefinition
+
title: ExpectedResult
<p><div><div>[{"title":"AnotherDefinition","tags":"Definitions","text":"This is the tiddler AnotherDefinition","custom":"Alpha"},{"title":"HelloThere","tags":"Definitions","text":"This is the tiddler HelloThere","custom":"Alpha"}]</div></div></p>
<p><div class="tc-test-case "><div>[{"title":"AnotherDefinition","tags":"Definitions","text":"This is the tiddler AnotherDefinition","custom":"Alpha"},{"title":"HelloThere","tags":"Definitions","text":"This is the tiddler HelloThere","custom":"Alpha"}]</div></div></p>

View File

@@ -20,4 +20,4 @@ This is the tiddler HelloThere
+
title: ExpectedResult
<p><div><div>[{"title":"HelloThere","tags":"Definitions","text":"This is the tiddler HelloThere","custom":"Alpha"}]</div></div></p>
<p><div class="tc-test-case "><div>[{"title":"HelloThere","tags":"Definitions","text":"This is the tiddler HelloThere","custom":"Alpha"}]</div></div></p>

View File

@@ -9,10 +9,10 @@ text: Standalone data widget to create individual tiddlers
title: Output
\whitespace trim
<$testcase template="$:/core/ui/testcases/RawJSONTemplate">
<$testcase template="$:/core/ui/testcases/RawJSONTemplate" class="my-class an-other-class">
<$data title="Epsilon" text="Theta"/>
</$testcase>
+
title: ExpectedResult
<p><div><div>[{"title":"Epsilon","text":"Theta"}]</div></div></p>
<p><div class="tc-test-case my-class an-other-class"><div>[{"title":"Epsilon","text":"Theta"}]</div></div></p>