Skip to content

Commit

Permalink
Merge branch '__rultor'
Browse files Browse the repository at this point in the history
  • Loading branch information
rultor committed Dec 5, 2023
2 parents 881ed60 + 5af6557 commit 9061ce9
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@
* Test cases for {@link VerifyMojo}.
*
* @since 0.31.0
* @todo #2546:90min Add test that checks the message of exception in case of
* warning, error and critical in xmir. According to
* eo-parser/src/main/resources/org/eolang/parser/fail-on-critical.xsl it includes
* filename and line inside.
*/
class VerifyMojoTest {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,10 @@ Raise an error if errors are found within program
<xsl:output encoding="UTF-8" method="xml"/>
<xsl:template match="/program/errors/error[@severity='critical']">
<xsl:message terminate="yes">
<xsl:text>Critical error identified: </xsl:text>
<xsl:text>Critical error identified:
</xsl:text>
<xsl:for-each select="/program/errors/error[@severity='critical']">
<xsl:value-of select="concat(text(), '; ')"/>
<xsl:value-of select="concat(' ', /program/@source, ', ', @line, ': ', text() , ';&#10;')"/>
</xsl:for-each>
</xsl:message>
<xsl:copy>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,10 @@ Raise an error if errors are found within program
<xsl:output encoding="UTF-8" method="xml"/>
<xsl:template match="/program/errors/error[@severity='error']">
<xsl:message terminate="yes">
<xsl:text>Errors identified: </xsl:text>
<xsl:text>Errors identified:
</xsl:text>
<xsl:for-each select="/program/errors/error[@severity='error']">
<xsl:value-of select="concat(text(), '; ')"/>
<xsl:value-of select="concat(' ', /program/@source, ', ', @line, ': ', text() , ';&#10;')"/>
</xsl:for-each>
</xsl:message>
<xsl:copy>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,10 @@ Raise an error if warnings are found within program
<xsl:output encoding="UTF-8" method="xml"/>
<xsl:template match="/program/errors/error[@severity='warning']">
<xsl:message terminate="yes">
<xsl:text>Warnings identified: </xsl:text>
<xsl:text>Warnings identified:
</xsl:text>
<xsl:for-each select="/program/errors/error[@severity='warning']">
<xsl:value-of select="concat(text(), '; ')"/>
<xsl:value-of select="concat(' ', /program/@source, ', ', @line, ': ', text() , ';&#10;')"/>
</xsl:for-each>
</xsl:message>
<xsl:copy>
Expand Down

1 comment on commit 9061ce9

@0pdd
Copy link

@0pdd 0pdd commented on 9061ce9 Dec 5, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Puzzle 2546-12d07944 discovered in eo-maven-plugin/src/test/java/org/eolang/maven/VerifyMojoTest.java) and submitted as #2674. Please, remember that the puzzle was not necessarily added in this particular commit. Maybe it was added earlier, but we discovered it only now.

Please sign in to comment.