Skip to content
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1,717 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Weather Routing Plugin for OpenCPN

Perform weather routing, see "data/WeatherRoutingInformation.html"

Copyright and License

The files under src/ are Copyright (c) Sean D'Epagnier 2016 - 2018 and distributed using a GPL version 3 license. Other files uses multitude of GPL compatible licenses, see the source files.

Building and Installing

See INSTALL

Unit Testing

The unit tests are disabled by default. To run the tests, define the relevant environment variable and run the tests as follows (from the build directory, as usual):

cmake -DOCPN_BUILD_TEST=ON ..
make
make test

You should see something like this:

Running tests...
/opt/homebrew/Cellar/cmake/3.30.5/bin/ctest --force-new-ctest-process
Test project weather_routing_pi/build
      Start  1: PolarTests.AssertionsBasic
 1/53 Test  #1: PolarTests.AssertionsBasic .....................   Passed    0.07 sec
      Start  2: PolarTests.ConstructorBasic
 2/53 Test  #2: PolarTests.ConstructorBasic ....................   Passed    0.01 sec
      Start  3: PolarTests.OpenFailed
 3/53 Test  #3: PolarTests.OpenFailed ..........................   Passed    0.01 sec
      Start  4: PolarTests.OpenSuccess
 4/53 Test  #4: PolarTests.OpenSuccess .........................   Passed    0.03 sec
 ...

All tests are intended to pass. If any tests fail, please report an issue, providing enough context for a developer to reproduce and fix the problem.

Test Coverage

gcov can be used to determine and display test coverage (i.e. the percentage of source code lines that are executed by automated unit tests) as follows (from the build directory, as usual):

make coverage

You should see something like this:

File 'IsoRoute.cpp'
Lines executed:60.44% of 771

File 'LineBufferOverlay.cpp'
Lines executed:63.95% of 172

File 'PlotDialog.cpp'
Lines executed:0.00% of 218

File 'Polar.cpp'
Lines executed:69.87% of 634

File 'PolygonRegion.cpp'
Lines executed:61.07% of 298

File 'Position.cpp'
Lines executed:43.85% of 317

Occasionally you might see an error like this:

Invalid .gcda File!

The simplest fix for this is simply to delete all the '.gcda' files in the build directory and it's subdirectories, and then run make gcov again to regenerate these "Google coverage data" files. For example (on Linux, MacOS and similar platforms):

 find . -name '*.gcda' | xargs rm    

PR's to increase the amount of automated testing, and overall test coverage are highly appreciated. Test code is located in the test directory.

License

The plugin code is licensed under the terms of the GPL v3+

Part of the icons made by Smashicons (https://www.flaticon.com/authors/smashicons) from Flaticon (https://www.flaticon.com/) and is licensed under CC BY 3.0 (http://creativecommons.org/licenses/by/3.0)

About

Weather Routing plugin for OpenCPN

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages