-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clean up highlighting issue, add GlossaryPassTest
* Message formatting shouldn't highlight at all and now doesn't * Highlighting changed to bold the first line of each message * Added a test case for teh GlossaryPass * Made HugoTestBase abstract so it won't run! Signed-off-by: reidspencer <reid.spencer@yoppworks.com>
- Loading branch information
1 parent
bb0ed1b
commit 09f2696
Showing
11 changed files
with
126 additions
and
110 deletions.
There are no files selected for viewing
23 changes: 23 additions & 0 deletions
23
hugo/src/test/scala/com/reactific/riddl/hugo/GlossaryPassTest.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.reactific.riddl.hugo | ||
|
||
import com.reactific.riddl.testkit.ValidatingTest | ||
import com.reactific.riddl.passes.Pass | ||
|
||
class GlossaryPassTest extends ValidatingTest { | ||
|
||
val dir = "testkit/src/test/input/" | ||
|
||
"GlossaryPass" must { | ||
"product glossary entries" in { | ||
parseAndValidateTestInput("glossary entries", "everything.riddl", dir) { case (root, pr) => | ||
if pr.messages.hasErrors then | ||
val errors = pr.messages.justErrors.format | ||
fail(errors) | ||
else | ||
val pass = new GlossaryPass(pr.input, pr.outputs, HugoCommand.Options()) | ||
val output: GlossaryOutput = Pass.runPass[GlossaryOutput](pr.input, pr.outputs, pass) | ||
output.entries.size must be(60) | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.