Skip to content

Commit

Permalink
Fix map (#609)
Browse files Browse the repository at this point in the history
<!-- Thanks for the contribution, this is awesome. -->

# PR Details
## Description

Changes were made to handle files that could be expected. This includes:
Files with newline characters
Files with only MapData
Files containing a MessageFrame along with MapData

Plugin was also cleaned up with a header file. 

## Related Issue

<!--- This project only accepts pull requests related to open issues -->
<!--- If suggesting a new feature or change, please discuss it in an
issue first -->
<!--- If fixing a bug, there should be an issue describing it with steps
to reproduce -->
#608

## Motivation and Context
These changes make the MAP plugin more robust because it's able to
handle MAP files that could be expected to be generated by a user.

## How Has This Been Tested?

<!--- Please describe in detail how you tested your changes. -->
<!--- Include details of your testing environment, and the tests you ran
to -->
<!--- see how your change affects other areas of the code, etc. -->
Tested using files with and without newline characters, files with and
without MessageFrames, and a combination of the two.

## Types of changes

<!--- What types of changes does your code introduce? Put an `x` in all
the boxes that apply: -->

- [X] Defect fix (non-breaking change that fixes an issue)
- [ ] New feature (non-breaking change that adds functionality)
- [ ] Breaking change (fix or feature that cause existing functionality
to change)

## Checklist:

<!--- Go over all the following points, and put an `x` in all the boxes
that apply. -->
<!--- If you're unsure about any of these, don't hesitate to ask. We're
here to help! -->

- [ ] I have added any new packages to the sonar-scanner.properties file
- [ ] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly.
- [X] I have read the **CONTRIBUTING** document.
[V2XHUB Contributing
Guide](https://github.com/usdot-fhwa-OPS/V2X-Hub/blob/develop/Contributing.md)
- [ ] I have added tests to cover my changes.
- [X] All new and existing tests passed.
  • Loading branch information
jwillmartin authored Jun 27, 2024
1 parent 8979d91 commit f933ff7
Show file tree
Hide file tree
Showing 3 changed files with 411 additions and 357 deletions.
2 changes: 1 addition & 1 deletion src/v2i-hub/MapPlugin/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
{
"key":"MAP_Files",
"default":"{ \"MapFiles\": [ {\"Action\":0, \"FilePath\":\"/var/www/plugins/MAP/MAP_9709_UPER.txt\"}] }",
"description":"JSON data defining a list of map files. One map file for each action set specified by the TSC."
"description":"JSON data defining a list of map files. One map file for each action set specified by the TSC."
}
]
}
Loading

0 comments on commit f933ff7

Please sign in to comment.