Skip to content

Commit

Permalink
added sanity tests
Browse files Browse the repository at this point in the history
  • Loading branch information
benediktschwab committed Jul 10, 2023
1 parent 468f727 commit e977788
Show file tree
Hide file tree
Showing 4 changed files with 538 additions and 8 deletions.
21 changes: 13 additions & 8 deletions .github/workflows/build-rtron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,37 +16,42 @@ jobs:
fail-fast: false

steps:
- name: Checkout
- name: "Checkout"
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Java
- name: "Set up Java"
uses: actions/setup-java@v3
with:
distribution: ${{ matrix.distribution }}
java-version: ${{ matrix.java }}
- name: Build with Gradle
- name: "Build with Gradle"
run: ./gradlew build --no-daemon
- name: Test local publishing
- name: "Test local publishing"
run: ./gradlew build publishToMavenLocal -Pskip.signing
if: matrix.os == 'ubuntu'

- name: "Build uber JAR with Gradle"
run: ./gradlew shadowJar
- name: "Sanity testing: Validation test runs"
run: java -jar ./rtron-cli/build/libs/rtron.jar validate-opendrive ./samples/datasets ./samples/datasets-out

build:
needs: test
runs-on: ubuntu-latest
steps:
- name: Checkout
- name: "Checkout"
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Java
- name: "Set up Java"
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '11'
- name: Build with Gradle
- name: "Build with Gradle"
run: ./gradlew shadowJar
- name: Upload build artifacts
- name: "Upload build artifacts"
uses: actions/upload-artifact@v3
with:
name: rtron-build
Expand Down
3 changes: 3 additions & 0 deletions samples/datasets/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Sample Datasets

This directory contains sample datasets created with [MathWorks RoadRunenr](https://mathworks.com/products/roadrunner.html).
78 changes: 78 additions & 0 deletions samples/datasets/basic_sample_01.xodr
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<OpenDRIVE>
<header date="2023-07-10T14:21:03" east="120.94215329013899" north="26.444963012876777" revMajor="1" revMinor="7" south="-27.49496296519306" version="1" west="-27.49496296519306"/>
<road id="0" junction="-1" length="200.0" name="Road 0" rule="RHT">
<type s="0.0" type="town">
<speed max="40.0" unit="mph"/>
</type>
<planView>
<geometry hdg="0.0" length="200.0" s="0.0" x="-100" y="0">
<line/>
</geometry>
</planView>
<elevationProfile>
<elevation a="0.0" b="0.0" c="0.0" d="0.0" s="0.0"/>
</elevationProfile>
<lateralProfile>
<superelevation a="0.0" b="0.0" c="0.0" d="0.0" s="0.0"/>
</lateralProfile>
<lanes>
<laneOffset a="0.0" b="0.0" c="0.0" d="0.0" s="0.0"/>
<laneSection s="0.0" singleSide="false">
<left>
<lane id="4" level="false" type="sidewalk">
<width a="2.0" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="none" weight="standard" width="0.0"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
<height inner="0.15239999999999998" outer="0.15239999999999998" sOffset="0.0"/>
</lane>
<lane id="3" level="false" type="curb">
<width a="0.6349999999999998" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="curb" weight="standard" width="0.15239999999999998"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
<height inner="0.15239999999999998" outer="0.15239999999999998" sOffset="0.0"/>
</lane>
<lane id="2" level="false" type="shoulder">
<width a="0.5" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="none" weight="standard" width="0.0"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
</lane>
<lane id="1" level="false" type="driving">
<width a="3.5" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="none" weight="standard" width="0.0"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
</lane>
</left>
<center>
<lane id="0" level="false" type="none">
<roadMark color="yellow" laneChange="none" material="standard" sOffset="0.0" type="solid solid" weight="standard" width="0.125"/>
</lane>
</center>
<right>
<lane id="-1" level="false" type="driving">
<width a="3.5" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="none" weight="standard" width="0.0"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
</lane>
<lane id="-2" level="false" type="shoulder">
<width a="0.5" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="none" weight="standard" width="0.0"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
</lane>
<lane id="-3" level="false" type="curb">
<width a="0.6349999999999998" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="curb" weight="standard" width="0.15239999999999998"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
<height inner="0.15239999999999998" outer="0.15239999999999998" sOffset="0.0"/>
</lane>
<lane id="-4" level="false" type="sidewalk">
<width a="2.0" b="0.0" c="0.0" d="0.0" sOffset="0.0"/>
<roadMark color="standard" laneChange="none" material="standard" sOffset="0.0" type="none" weight="standard" width="0.0"/>
<speed max="40.0" sOffset="0.0" unit="mph"/>
<height inner="0.15239999999999998" outer="0.15239999999999998" sOffset="0.0"/>
</lane>
</right>
</laneSection>
</lanes>
</road>
</OpenDRIVE>
Loading

0 comments on commit e977788

Please sign in to comment.