Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a PEG parser #75

Draft
wants to merge 34 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
90ad505
Adding parboiled dependency
kinow Nov 11, 2021
aa2f54b
Rename parser, and add Version, Plan, TestSet, and Test Lines rules.
kinow Nov 12, 2021
db42f99
Add package-info.java
kinow Nov 13, 2021
7a91fce
Add header license
kinow Nov 13, 2021
023e7a9
Add Javadoc
kinow Nov 13, 2021
5b3d2a7
Parser static fields can be final
kinow Nov 14, 2021
83d544f
Update pom.xml with checkstyle plugin version, and remove maven site …
kinow Nov 14, 2021
2fc26ce
Update unit tests for Windows build
kinow Nov 14, 2021
44d97ce
Add directives
kinow Nov 14, 2021
c92c834
Add Bailout
kinow Nov 15, 2021
7dc73d6
Add FIXME note about the multiple EOL (parboiled)
kinow Nov 15, 2021
b4447c9
Add Diagnostics
kinow Nov 15, 2021
e3d2ac5
Preprocess input, replacing strings. Handle test result comment
kinow Nov 18, 2021
dea6054
Add comment to BailOut
kinow Nov 18, 2021
dd6c04e
Support strings with hashes in directives and diagnostics
kinow Nov 18, 2021
0eb2675
Add comments
kinow Nov 18, 2021
f6376f2
Remove hack for multiple lines (now handled in preprocess method)
kinow Nov 18, 2021
2907b85
A Test Plan can appear at the beginning or at the end
kinow Nov 18, 2021
2af8ce4
A test plan can also have comments
kinow Nov 18, 2021
207f068
Uncomment more text, now testing complete TAP Stream
kinow Nov 18, 2021
8bc2744
Use Java 11
kinow Dec 2, 2021
be519f4
Use helper function to print the tree, handle indentation, and parse …
kinow Dec 2, 2021
ea69911
Add SpotBugs configuration and suppress for main method (tests)
kinow Dec 2, 2021
519fcf4
Remove JDK 8 from GH actions
kinow Dec 2, 2021
e7a4613
Tap header is optional
kinow Dec 3, 2021
b738a7e
Parse all existing files with new parser and report failures, success…
kinow Dec 3, 2021
0f839b9
Ignore bogus TAP streams, and handle ... in strings when not terminat…
kinow Dec 3, 2021
46c18db
Fixing imports and renaming files
kinow Dec 6, 2022
9b03e23
Upgrade to JUnit 5
kinow Dec 6, 2022
d1a3d47
Use JUnit 5 DynamicTests feature and make build fail for PEG parser
kinow Dec 6, 2022
184cc65
Add javadocs and comments. Guess the indent level from the input stre…
kinow Dec 6, 2022
f7039cf
Do not pass comments char to parboiled (see comment)
kinow Dec 6, 2022
2ce45a7
Update parboiled, create parser handling recursion
kinow Dec 6, 2022
bd91ad5
Mark more tests as invalid/pending
kinow Dec 6, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@ jobs:
strategy:
matrix:
os: [ ubuntu-latest ]
java: [ 8, 11 ]
java: [ 11 ]
experimental: [ false ]
include:
- java: 17
os: ubuntu-latest
experimental: true
- java: 8
- java: 11
os: windows-latest
experimental: true
steps:
Expand Down
52 changes: 26 additions & 26 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
<description>tap4j</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<java.version>1.8</java.version>
<java.version>11</java.version>
<junit.version>5.9.1</junit.version>
</properties>
<url>http://tupilabs.github.io/tap4j</url>
<inceptionYear>2010</inceptionYear>
Expand Down Expand Up @@ -91,11 +92,23 @@
<artifactId>snakeyaml</artifactId>
<version>1.33</version>
</dependency>
<!-- PEG -->
<dependency>
<groupId>org.parboiled</groupId>
<artifactId>parboiled-java</artifactId>
<version>1.4.1</version>
</dependency>
<!-- testing -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.13.2</version>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.11.0</version>
<scope>test</scope>
</dependency>
</dependencies>
Expand All @@ -105,38 +118,38 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.0</version>
<version>3.10.1</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
<release>${java.version}</release>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.0.1</version>
<version>3.4.1</version>
<configuration>
<source>${java.version}</source>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.rat</groupId>
<artifactId>apache-rat-plugin</artifactId>
<version>0.13</version>
<version>0.15</version>
<configuration>
<ignoreErrors>true</ignoreErrors>
</configuration>
</plugin>
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<version>3.1.12.2</version>
<version>3.1.0-RC4</version>
<configuration>
<!-- <excludeFilterFile>${basedir}/spotbugs-exclude-filter.xml</excludeFilterFile> -->
<excludeFilterFile>${basedir}/src/config/spotbugs-exclude-filter.xml</excludeFilterFile>
</configuration>
</plugin>
<plugin>
<artifactId>maven-checkstyle-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<configLocation>${basedir}/src/config/checkstyle.xml</configLocation>
<includeTestSourceDirectory>true</includeTestSourceDirectory>
Expand All @@ -145,21 +158,8 @@
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<version>3.7.1</version>
<dependencies>
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-module-markdown</artifactId>
<version>1.10</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>3.0.0</version>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M7</version>
</plugin>
</plugins>
</build>
Expand Down
38 changes: 38 additions & 0 deletions src/config/spotbugs-exclude-filter.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<?xml version="1.0"?>
<!--
The MIT License

Copyright (c) 2010 tap4j team (see AUTHORS)

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
-->

<!--
This file contains some false positive bugs detected by spotbugs. Their
false positive nature has been analyzed individually and they have been
put here to instruct findbugs it must ignore them.
-->
<FindBugsFilter>
<!-- For tests only -->
<Match>
<Class name="com.tupilabs.tap4j.Tap13Parser" />
<Method name="main" />
<Bug pattern="DM_DEFAULT_ENCODING" />
</Match>
</FindBugsFilter>
Loading