h3 3.6.0 → 3.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (175) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ruby_ci.yml +30 -0
  3. data/.rubocop.yml +1 -1
  4. data/.ruby-version +1 -0
  5. data/CHANGELOG.md +39 -0
  6. data/Gemfile.lock +6 -24
  7. data/LICENSE.md +1 -1
  8. data/README.md +2 -3
  9. data/ext/h3/src/.github/workflows/test-linux.yml +118 -0
  10. data/ext/h3/src/.github/workflows/test-macos.yml +42 -0
  11. data/ext/h3/src/.github/workflows/test-website.yml +32 -0
  12. data/ext/h3/src/.github/workflows/test-windows.yml +44 -0
  13. data/ext/h3/src/.gitignore +5 -0
  14. data/ext/h3/src/.travis.yml +20 -42
  15. data/ext/h3/src/CHANGELOG.md +57 -0
  16. data/ext/h3/src/CMakeLists.txt +135 -33
  17. data/ext/h3/src/CONTRIBUTING.md +1 -1
  18. data/ext/h3/src/README.md +61 -11
  19. data/ext/h3/src/RELEASE.md +3 -1
  20. data/ext/h3/src/VERSION +1 -1
  21. data/ext/h3/src/dev-docs/RFCs/rfc-template.md +21 -0
  22. data/ext/h3/src/dev-docs/RFCs/v4.0.0/error-handling-rfc.md +21 -0
  23. data/ext/h3/src/dev-docs/RFCs/v4.0.0/names_for_concepts_types_functions.md +276 -0
  24. data/ext/h3/src/dev-docs/RFCs/v4.0.0/overrideable-allocators-rfc.md +141 -0
  25. data/ext/h3/src/dev-docs/RFCs/v4.0.0/polyfill-modes-rfc.md +21 -0
  26. data/ext/h3/src/dev-docs/RFCs/v4.0.0/vertex-mode-rfc.md +50 -0
  27. data/ext/h3/src/dev-docs/build_windows.md +6 -1
  28. data/ext/h3/src/dev-docs/creating_bindings.md +3 -3
  29. data/ext/h3/src/dev-docs/custom_alloc.md +27 -0
  30. data/ext/h3/src/docs/{overview/mainpage.md → README.md} +2 -3
  31. data/ext/h3/src/docs/api/misc.md +76 -0
  32. data/ext/h3/src/docs/community/applications.md +1 -0
  33. data/ext/h3/src/docs/community/bindings.md +10 -0
  34. data/ext/h3/src/docs/community/tutorials.md +8 -3
  35. data/ext/h3/src/docs/core-library/coordsystems.md +5 -4
  36. data/ext/h3/src/docs/core-library/filters.md +8 -9
  37. data/ext/h3/src/docs/core-library/geoToH3desc.md +2 -3
  38. data/ext/h3/src/docs/core-library/h3ToGeoBoundaryDesc.md +4 -5
  39. data/ext/h3/src/docs/core-library/h3ToGeoDesc.md +3 -4
  40. data/ext/h3/src/docs/core-library/h3indexing.md +26 -17
  41. data/ext/h3/src/docs/core-library/overview.md +2 -3
  42. data/ext/h3/src/docs/core-library/restable.md +1 -2
  43. data/ext/h3/src/docs/core-library/usage.md +1 -2
  44. data/ext/h3/src/docs/table-of-contents.json +47 -0
  45. data/ext/h3/src/docs/{overview/usecases.md → usecases.md} +6 -11
  46. data/ext/h3/src/scripts/binding_functions.sh +1 -1
  47. data/ext/h3/src/scripts/coverage.sh.in +1 -1
  48. data/ext/h3/src/scripts/update_version.sh +2 -2
  49. data/ext/h3/src/src/apps/applib/include/args.h +1 -0
  50. data/ext/h3/src/src/apps/applib/include/test.h +1 -0
  51. data/ext/h3/src/src/apps/applib/include/utility.h +7 -1
  52. data/ext/h3/src/src/apps/applib/lib/args.c +2 -0
  53. data/ext/h3/src/src/apps/applib/lib/kml.c +2 -0
  54. data/ext/h3/src/src/apps/applib/lib/test.c +1 -0
  55. data/ext/h3/src/src/apps/applib/lib/utility.c +133 -2
  56. data/ext/h3/src/src/apps/benchmarks/benchmarkH3Api.c +1 -1
  57. data/ext/h3/src/{website/html.config.js → src/apps/benchmarks/benchmarkH3UniEdge.c} +15 -12
  58. data/ext/h3/src/src/apps/filters/h3ToComponents.c +1 -0
  59. data/ext/h3/src/src/apps/filters/h3ToGeo.c +1 -0
  60. data/ext/h3/src/src/apps/filters/h3ToGeoBoundary.c +1 -0
  61. data/ext/h3/src/src/apps/filters/h3ToLocalIj.c +1 -0
  62. data/ext/h3/src/src/apps/filters/hexRange.c +1 -0
  63. data/ext/h3/src/src/apps/filters/kRing.c +1 -0
  64. data/ext/h3/src/src/apps/filters/localIjToH3.c +1 -0
  65. data/ext/h3/src/src/apps/miscapps/generateFaceCenterPoint.c +1 -0
  66. data/ext/h3/src/src/apps/miscapps/generateNumHexagons.c +1 -0
  67. data/ext/h3/src/src/apps/miscapps/generatePentagonDirectionFaces.c +67 -0
  68. data/ext/h3/src/src/apps/miscapps/h3ToGeoBoundaryHier.c +1 -0
  69. data/ext/h3/src/src/apps/miscapps/h3ToGeoHier.c +1 -0
  70. data/ext/h3/src/src/apps/miscapps/h3ToHier.c +1 -0
  71. data/ext/h3/src/src/apps/testapps/mkRandGeo.c +1 -0
  72. data/ext/h3/src/src/apps/testapps/mkRandGeoBoundary.c +1 -0
  73. data/ext/h3/src/src/apps/testapps/testBBox.c +1 -0
  74. data/ext/h3/src/src/apps/testapps/testBaseCells.c +15 -1
  75. data/ext/h3/src/src/apps/testapps/testCompact.c +109 -2
  76. data/ext/h3/src/src/apps/testapps/testCoordIj.c +1 -0
  77. data/ext/h3/src/src/apps/testapps/testGeoCoord.c +47 -8
  78. data/ext/h3/src/src/apps/testapps/testGeoToH3.c +1 -0
  79. data/ext/h3/src/src/apps/testapps/testH3Api.c +1 -0
  80. data/ext/h3/src/src/apps/testapps/testH3CellArea.c +47 -0
  81. data/ext/h3/src/src/apps/testapps/testH3CellAreaExhaustive.c +180 -0
  82. data/ext/h3/src/src/apps/testapps/testH3Distance.c +1 -0
  83. data/ext/h3/src/src/apps/testapps/testH3DistanceExhaustive.c +1 -0
  84. data/ext/h3/src/src/apps/testapps/testH3GetFaces.c +1 -0
  85. data/ext/h3/src/src/apps/testapps/testH3Index.c +33 -3
  86. data/ext/h3/src/src/apps/testapps/testH3Line.c +1 -0
  87. data/ext/h3/src/src/apps/testapps/testH3LineExhaustive.c +1 -0
  88. data/ext/h3/src/src/apps/testapps/testH3Memory.c +175 -0
  89. data/ext/h3/src/src/apps/testapps/testH3NeighborRotations.c +1 -0
  90. data/ext/h3/src/src/apps/testapps/testH3SetToLinkedGeo.c +1 -0
  91. data/ext/h3/src/src/apps/testapps/testH3SetToVertexGraph.c +1 -0
  92. data/ext/h3/src/src/apps/testapps/testH3ToCenterChild.c +1 -0
  93. data/ext/h3/src/src/apps/testapps/testH3ToChildren.c +1 -0
  94. data/ext/h3/src/src/apps/testapps/testH3ToGeo.c +1 -0
  95. data/ext/h3/src/src/apps/testapps/testH3ToGeoBoundary.c +1 -0
  96. data/ext/h3/src/src/apps/testapps/testH3ToLocalIj.c +12 -6
  97. data/ext/h3/src/src/apps/testapps/testH3ToLocalIjExhaustive.c +1 -0
  98. data/ext/h3/src/src/apps/testapps/testH3ToParent.c +1 -0
  99. data/ext/h3/src/src/apps/testapps/testH3UniEdge.c +45 -16
  100. data/ext/h3/src/src/apps/testapps/testH3UniEdgeExhaustive.c +111 -0
  101. data/ext/h3/src/src/apps/testapps/testHexRanges.c +1 -0
  102. data/ext/h3/src/src/apps/testapps/testHexRing.c +1 -0
  103. data/ext/h3/src/src/apps/testapps/testKRing.c +19 -0
  104. data/ext/h3/src/src/apps/testapps/testLinkedGeo.c +1 -0
  105. data/ext/h3/src/src/apps/testapps/testMaxH3ToChildrenSize.c +1 -0
  106. data/ext/h3/src/src/apps/testapps/testPentagonIndexes.c +1 -0
  107. data/ext/h3/src/src/apps/testapps/testPolyfill.c +72 -9
  108. data/ext/h3/src/src/apps/testapps/testPolyfillReported.c +157 -0
  109. data/ext/h3/src/src/apps/testapps/testPolygon.c +27 -1
  110. data/ext/h3/src/src/apps/testapps/testVec2d.c +1 -0
  111. data/ext/h3/src/src/apps/testapps/testVec3d.c +1 -0
  112. data/ext/h3/src/src/apps/testapps/testVertex.c +66 -0
  113. data/ext/h3/src/src/apps/testapps/testVertexGraph.c +1 -0
  114. data/ext/h3/src/src/h3lib/include/algos.h +8 -0
  115. data/ext/h3/src/src/h3lib/include/alloc.h +40 -0
  116. data/ext/h3/src/src/h3lib/include/baseCells.h +4 -0
  117. data/ext/h3/src/src/h3lib/include/bbox.h +4 -1
  118. data/ext/h3/src/src/h3lib/include/faceijk.h +3 -2
  119. data/ext/h3/src/src/h3lib/include/geoCoord.h +2 -3
  120. data/ext/h3/src/src/h3lib/include/h3Index.h +37 -4
  121. data/ext/h3/src/src/h3lib/include/h3api.h.in +65 -17
  122. data/ext/h3/src/src/h3lib/include/linkedGeo.h +1 -0
  123. data/ext/h3/src/src/h3lib/include/polygon.h +1 -0
  124. data/ext/h3/src/src/h3lib/include/polygonAlgos.h +1 -0
  125. data/ext/h3/src/src/h3lib/include/vertex.h +44 -0
  126. data/ext/h3/src/src/h3lib/include/vertexGraph.h +1 -0
  127. data/ext/h3/src/src/h3lib/lib/algos.c +304 -76
  128. data/ext/h3/src/src/h3lib/lib/baseCells.c +26 -4
  129. data/ext/h3/src/src/h3lib/lib/bbox.c +56 -27
  130. data/ext/h3/src/src/h3lib/lib/coordijk.c +2 -0
  131. data/ext/h3/src/src/h3lib/lib/faceijk.c +32 -21
  132. data/ext/h3/src/src/h3lib/lib/geoCoord.c +162 -44
  133. data/ext/h3/src/src/h3lib/lib/h3Index.c +83 -42
  134. data/ext/h3/src/src/h3lib/lib/h3UniEdge.c +42 -57
  135. data/ext/h3/src/src/h3lib/lib/linkedGeo.c +20 -15
  136. data/ext/h3/src/src/h3lib/lib/localij.c +1 -1
  137. data/ext/h3/src/src/h3lib/lib/polygon.c +2 -0
  138. data/ext/h3/src/src/h3lib/lib/vec2d.c +1 -0
  139. data/ext/h3/src/src/h3lib/lib/vec3d.c +1 -0
  140. data/ext/h3/src/src/h3lib/lib/vertex.c +134 -0
  141. data/ext/h3/src/src/h3lib/lib/vertexGraph.c +8 -5
  142. data/ext/h3/src/website/.eslintignore +2 -0
  143. data/ext/h3/src/website/.gitignore +57 -0
  144. data/ext/h3/src/website/.nvmrc +1 -0
  145. data/ext/h3/src/website/README.md +8 -6
  146. data/ext/h3/src/website/gatsby-config.js +83 -0
  147. data/ext/h3/src/website/package.json +20 -12
  148. data/ext/h3/src/website/scripts/build-to-gh-pages.sh +7 -5
  149. data/ext/h3/src/website/src/.gitkeep +0 -0
  150. data/ext/h3/src/website/templates/documentation.jsx +129 -0
  151. data/ext/h3/src/website/yarn.lock +13723 -0
  152. data/h3.gemspec +2 -2
  153. data/lib/h3/bindings/base.rb +14 -4
  154. data/lib/h3/bindings/private.rb +12 -9
  155. data/lib/h3/hierarchy.rb +0 -18
  156. data/lib/h3/indexing.rb +0 -18
  157. data/lib/h3/inspection.rb +3 -59
  158. data/lib/h3/miscellaneous.rb +119 -14
  159. data/lib/h3/regions.rb +3 -0
  160. data/lib/h3/traversal.rb +0 -18
  161. data/lib/h3/unidirectional_edges.rb +5 -60
  162. data/lib/h3/version.rb +1 -1
  163. data/spec/geo_json_spec.rb +8 -0
  164. data/spec/miscellaneous_spec.rb +117 -0
  165. data/spec/{region_spec.rb → regions_spec.rb} +1 -1
  166. data/spec/spec_helper.rb +2 -2
  167. metadata +44 -36
  168. data/.travis.yml +0 -11
  169. data/ext/h3/src/.ycm_extra_conf.py +0 -92
  170. data/ext/h3/src/appveyor.yml +0 -50
  171. data/ext/h3/src/website/src/config.js +0 -46
  172. data/ext/h3/src/website/src/mdRoutes.js +0 -151
  173. data/ext/h3/src/website/src/styles/_variables.scss +0 -16
  174. data/ext/h3/src/website/src/styles/index.scss +0 -3
  175. data/ext/h3/src/website/static/index.html +0 -15
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4344398c78a4d188c270838673195d9e16e1a400ab157ec34fa45a006fc17c2b
4
- data.tar.gz: 0ee405d8aefdb3fa062079903ae586da85598b2a12e87c4b029c11aa3d1c73f2
3
+ metadata.gz: acb338f235d3507df322d3e148a135fe72d67911ba05edf9af82873ac190a556
4
+ data.tar.gz: 506b3fddfec2bdd388a57a8e08aeac7522508b8f6e04e9f1d421a6611367890a
5
5
  SHA512:
6
- metadata.gz: c385c0805d7b8e59c2610048ff71aacaf9e4b5a8aae21385a36ae42d47f036eab812296752ff108146655ed2fc1b87800246889d3393bf1a6940dfce43e34a4e
7
- data.tar.gz: f8aeaf98281a57718266fb5eb259d269e1dbf4804c02fb0af25327c39594084eba87fbdb504446066330b5c57368aaedab856c45bf0a437726fd6d95d7b159b0
6
+ metadata.gz: e73b0b8d43710cf5b0a802bd08a0a87f607990c162c34eddda36940b10890f6bc252873d96431d2063b659e32af55336a0edd7d748e82aebc3d5ad7d0adfc54c
7
+ data.tar.gz: 7bf43c08a6fe09da1a4b0cbf9f688d56a3d0ec3bab060af939f422f39b0f1e43ec40e45f50b2aa14fd8c486ace24ef4beb7b1e50c9e440df9f0f1d67212e5c64
@@ -0,0 +1,30 @@
1
+ name: Ruby CI
2
+
3
+ on:
4
+ push:
5
+ branches: [ master ]
6
+ pull_request:
7
+ branches: [ master ]
8
+
9
+ jobs:
10
+ test:
11
+
12
+ runs-on: ubuntu-latest
13
+
14
+ strategy:
15
+ matrix:
16
+ ruby-version: [3.0.1, 2.7.3, 2.6.7, 2.5.9]
17
+
18
+ steps:
19
+ - uses: actions/checkout@v2
20
+ - name: Set up Ruby ${{ matrix.ruby-version }}
21
+ uses: ruby/setup-ruby@477b21f02be01bcb8030d50f37cfec92bfa615b6
22
+ with:
23
+ ruby-version: ${{ matrix.ruby-version }}
24
+ bundler-cache: true
25
+ - name: Install system dependencies
26
+ run: sudo apt-get install cmake make gcc libtool
27
+ - name: Install gems
28
+ run: bundle install
29
+ - name: Run tests
30
+ run: bundle exec rake spec
data/.rubocop.yml CHANGED
@@ -1,5 +1,5 @@
1
1
  AllCops:
2
- TargetRubyVersion: 2.3
2
+ TargetRubyVersion: 2.5
3
3
  Exclude:
4
4
  - "vendor/**/*"
5
5
  - "db/schema.rb"
data/.ruby-version ADDED
@@ -0,0 +1 @@
1
+ 2.7.2
data/CHANGELOG.md CHANGED
@@ -6,6 +6,45 @@ This project adheres to [Semantic Versioning](http://semver.org/).
6
6
 
7
7
  We track the MAJOR and MINOR version levels of Uber's H3 project (https://github.com/uber/h3) but maintain independent patch levels so we can make small fixes and non breaking changes.
8
8
 
9
+ ## [3.7.2] - 2020-07-17
10
+ ### Fixed
11
+ - kRing of invalid indexes should not crash.
12
+
13
+ ## [3.7.1] - 2020-10-7
14
+ ### Added
15
+ - Area and haversine distance functions:
16
+ - `cellAreaRads2`
17
+ - `cellAreaKm2`
18
+ - `cellAreaM2`
19
+ - `pointDistRads`
20
+ - `pointDistKm`
21
+ - `pointDistM`
22
+ - `exactEdgeLengthRads`
23
+ - `exactEdgeLengthKm`
24
+ - `exactEdgeLengthM`
25
+
26
+ ### Changed
27
+ - Speeds up `getH3UnidirectionalEdgeBoundary` by about 3x.
28
+
29
+ ### Fixed
30
+ - Finding invalid edge boundaries should not crash.
31
+
32
+ ## [3.6.4] - 2020-7-2
33
+ ### Changed
34
+ - Reinstate new `polyfill` algorithm for up to 3x perf boost.
35
+
36
+ ## [3.6.2] - 2020-1-8
37
+ ### Changed
38
+ - Revert new polyfill algorithm until reported issues are fixed.
39
+ - Remove deprecated methods: (#66)
40
+
41
+ ## [3.6.1] - 2019-11-23
42
+ ### Fixed
43
+ - `compact` handles zero length input correctly.
44
+ - `bboxHexRadius` scaling factor adjusted to guarantee containment for `polyfill`.
45
+ - `polyfill` new algorithm for up to 3x perf boost.
46
+ - Fix CMake targets for KML generation.
47
+
9
48
  ## [3.6.0] - 2019-8-14
10
49
  ### Added
11
50
  - `center_child` method to find center child at given resolution (#62).
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- h3 (3.6.0)
4
+ h3 (3.7.2)
5
5
  ffi (~> 1.9)
6
6
  rgeo-geojson (~> 2.1)
7
7
  zeitwerk (~> 2.1)
@@ -9,18 +9,10 @@ PATH
9
9
  GEM
10
10
  remote: https://rubygems.org/
11
11
  specs:
12
- coveralls (0.8.22)
13
- json (>= 1.8, < 3)
14
- simplecov (~> 0.16.1)
15
- term-ansicolor (~> 1.3)
16
- thor (~> 0.19.4)
17
- tins (~> 1.6)
18
12
  diff-lcs (1.3)
19
- docile (1.3.1)
20
- ffi (1.11.1)
21
- json (2.1.0)
22
- rake (12.3.2)
23
- rgeo (2.1.0)
13
+ ffi (1.15.3)
14
+ rake (12.3.3)
15
+ rgeo (2.3.0)
24
16
  rgeo-geojson (2.1.1)
25
17
  rgeo (>= 1.0.0)
26
18
  rspec (3.8.0)
@@ -36,27 +28,17 @@ GEM
36
28
  diff-lcs (>= 1.2.0, < 2.0)
37
29
  rspec-support (~> 3.8.0)
38
30
  rspec-support (3.8.0)
39
- simplecov (0.16.1)
40
- docile (~> 1.1)
41
- json (>= 1.8, < 3)
42
- simplecov-html (~> 0.10.0)
43
- simplecov-html (0.10.2)
44
- term-ansicolor (1.7.0)
45
- tins (~> 1.0)
46
- thor (0.19.4)
47
- tins (1.20.2)
48
31
  yard (0.9.20)
49
- zeitwerk (2.1.9)
32
+ zeitwerk (2.4.2)
50
33
 
51
34
  PLATFORMS
52
35
  ruby
53
36
 
54
37
  DEPENDENCIES
55
- coveralls (~> 0.8)
56
38
  h3!
57
39
  rake (~> 12.3)
58
40
  rspec (~> 3.8)
59
41
  yard (~> 0.9)
60
42
 
61
43
  BUNDLED WITH
62
- 1.17.2
44
+ 2.1.4
data/LICENSE.md CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2018-2019 Stuart Delivery
3
+ Copyright (c) 2018-2020 Stuart Delivery
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/README.md CHANGED
@@ -2,8 +2,7 @@
2
2
 
3
3
  ![h3](https://user-images.githubusercontent.com/98526/50283275-48177300-044d-11e9-8337-eba8d3cc88a2.png)
4
4
 
5
- [![Build Status](https://travis-ci.org/StuartApp/h3_ruby.svg?branch=master)](https://travis-ci.org/seanhandley/h3_ruby)
6
- [![Maintainability](https://api.codeclimate.com/v1/badges/74a47e7fa516588ab545/maintainability)](https://codeclimate.com/repos/5ca38395a86379029800281f/maintainability) [![Coverage Status](https://coveralls.io/repos/github/StuartApp/h3_ruby/badge.svg?branch=master)](https://coveralls.io/github/StuartApp/h3_ruby?branch=master) [![Gem Version](https://badge.fury.io/rb/h3.svg)](https://badge.fury.io/rb/h3)
5
+ ![Build Status](https://github.com/StuartApp/h3_ruby/actions/workflows/ruby_ci/badge.svg) [![Coverage Status](https://coveralls.io/repos/github/StuartApp/h3_ruby/badge.svg?branch=master)](https://coveralls.io/github/StuartApp/h3_ruby?branch=master) [![Maintainability](https://api.codeclimate.com/v1/badges/74a47e7fa516588ab545/maintainability)](https://codeclimate.com/repos/5ca38395a86379029800281f/maintainability) [![Gem Version](https://badge.fury.io/rb/h3.svg)](https://badge.fury.io/rb/h3)
7
6
 
8
7
  Ruby-to-C bindings for Uber's [H3 library](https://uber.github.io/h3/).
9
8
 
@@ -39,7 +38,7 @@ or add it to your Gemfile
39
38
 
40
39
  ```ruby
41
40
  # Gemfile
42
- gem "h3", "~> 3.2"
41
+ gem "h3", "~> 3.7"
43
42
  ```
44
43
 
45
44
  ## Usage
@@ -0,0 +1,118 @@
1
+ name: test-linux
2
+
3
+ on:
4
+ push:
5
+ branches: [master, stable-*]
6
+ pull_request:
7
+ branches: [master, stable-*]
8
+
9
+ jobs:
10
+ tests:
11
+ name: Test Compile ${{ matrix.compiler }}
12
+ runs-on: ubuntu-latest
13
+ env:
14
+ CC: ${{ matrix.compiler }}
15
+
16
+ strategy:
17
+ matrix:
18
+ compiler: [clang, gcc]
19
+
20
+ steps:
21
+ - uses: actions/checkout@v2.1.1
22
+
23
+ - name: Install Doxygen
24
+ run: |
25
+ sudo apt update
26
+ sudo apt-get install doxygen graphviz clang-format-9
27
+
28
+ - name: Configure build
29
+ run: cmake -Bbuild -DWARNINGS_AS_ERRORS=ON .
30
+
31
+ - name: Formatting check
32
+ working-directory: build
33
+ run: |
34
+ clang-format-9 --version
35
+ make format
36
+ git diff --exit-code
37
+
38
+ - name: Build
39
+ working-directory: build
40
+ run: make
41
+
42
+ - name: binding-functions
43
+ working-directory: build
44
+ run: |
45
+ make binding-functions
46
+ test -s binding-functions
47
+
48
+ - name: Tests
49
+ working-directory: build
50
+ run: |
51
+ make test
52
+ sudo make install
53
+
54
+ # Note the packages aren't used to test the examples below
55
+ - name: Test packaging
56
+ working-directory: build
57
+ run: cpack -D CPACK_PACKAGE_CONTACT="Test build in CI"
58
+
59
+ - name: Examples
60
+ run: |
61
+ mkdir build/examples
62
+ cd build/examples
63
+ cmake ../../examples
64
+ make
65
+ make test
66
+
67
+ valgrind-tests:
68
+ name: Test Valgrind
69
+ runs-on: ubuntu-latest
70
+
71
+ steps:
72
+ - uses: actions/checkout@v2.1.1
73
+
74
+ - name: Install Valgrind
75
+ run: |
76
+ sudo apt update
77
+ sudo apt-get install valgrind
78
+
79
+ - name: Configure build
80
+ run: cmake -Bbuild -DCMAKE_BUILD_TYPE=Debug -DWRAP_VALGRIND=ON .
81
+
82
+ - name: Build
83
+ working-directory: build
84
+ run: make
85
+
86
+ - name: Tests
87
+ working-directory: build
88
+ env:
89
+ CTEST_OUTPUT_ON_FAILURE: 1
90
+ run: make test-fast
91
+
92
+ coverage-tests:
93
+ name: Coverage
94
+ runs-on: ubuntu-latest
95
+ env:
96
+ CC: gcc
97
+
98
+ steps:
99
+ - uses: actions/checkout@v2.1.1
100
+
101
+ - name: Install lcov
102
+ run: |
103
+ sudo apt update
104
+ sudo apt-get install lcov
105
+
106
+ - name: Configure build
107
+ run: cmake -DCMAKE_BUILD_TYPE=Debug -DWARNINGS_AS_ERRORS=ON -DH3_PREFIX=testprefix_ .
108
+
109
+ - name: Build
110
+ run: make
111
+
112
+ - name: Tests
113
+ run: make coverage
114
+
115
+ - uses: coverallsapp/github-action@master
116
+ with:
117
+ path-to-lcov: ./coverage.cleaned.info
118
+ github-token: ${{ secrets.GITHUB_TOKEN }}
@@ -0,0 +1,42 @@
1
+ name: test-macos
2
+
3
+ on:
4
+ push:
5
+ branches: [master, stable-*]
6
+ pull_request:
7
+ branches: [master, stable-*]
8
+
9
+ jobs:
10
+ tests:
11
+ name: Test Compile ${{ matrix.compiler }}
12
+ runs-on: macos-latest
13
+
14
+ steps:
15
+ - uses: actions/checkout@v2.1.1
16
+
17
+ - name: Configure build
18
+ run: cmake -Bbuild -DWARNINGS_AS_ERRORS=ON .
19
+
20
+ - name: Build
21
+ working-directory: build
22
+ run: make
23
+
24
+ - name: binding-functions
25
+ working-directory: build
26
+ run: |
27
+ make binding-functions
28
+ test -s binding-functions
29
+
30
+ - name: Tests
31
+ working-directory: build
32
+ run: |
33
+ make test
34
+ sudo make install
35
+
36
+ - name: Examples
37
+ run: |
38
+ mkdir build/examples
39
+ cd build/examples
40
+ cmake ../../examples
41
+ make
42
+ make test
@@ -0,0 +1,32 @@
1
+ name: test-website
2
+
3
+ on:
4
+ push:
5
+ branches: [master, stable-*]
6
+ pull_request:
7
+ branches: [master, stable-*]
8
+
9
+ jobs:
10
+ tests:
11
+ name: Test Website and FOSSA
12
+ runs-on: ubuntu-latest
13
+
14
+ steps:
15
+ - uses: actions/checkout@v2.1.1
16
+
17
+ - uses: actions/setup-node@v1
18
+ with:
19
+ node-version: 12.x
20
+
21
+ - name: Install FOSSA
22
+ run: |
23
+ curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install.sh | sudo bash
24
+
25
+ - name: Test Website Build
26
+ working-directory: website
27
+ run: |
28
+ yarn
29
+ yarn build
30
+
31
+ - name: Submit FOSSA report
32
+ run: if [ -n "${{ secrets.FOSSA_API_KEY }}" ]; then fossa; fi
@@ -0,0 +1,44 @@
1
+ name: test-windows
2
+
3
+ on:
4
+ push:
5
+ branches: [master, stable-*]
6
+ pull_request:
7
+ branches: [master, stable-*]
8
+
9
+ jobs:
10
+ tests:
11
+ name: Test Compile ${{ matrix.config }} ${{ matrix.arch }}
12
+ runs-on: windows-latest
13
+ env:
14
+ CC: cl.exe
15
+ CXX: cl.exe
16
+
17
+ strategy:
18
+ matrix:
19
+ config: [Release, Debug]
20
+ arch: [Win32, x64]
21
+
22
+ steps:
23
+ - uses: actions/checkout@v2.1.1
24
+
25
+ - name: Configure build
26
+ shell: cmd
27
+ run: cmake -Bbuild -A ${{ matrix.arch }} -DWARNINGS_AS_ERRORS=ON -DBUILD_SHARED_LIBS=OFF -DBUILD_TESTING=ON .
28
+
29
+ - name: Build
30
+ working-directory: build
31
+ run: cmake --build . --config ${{ matrix.config }}
32
+
33
+ - name: binding-functions
34
+ working-directory: build
35
+ run: |
36
+ cmake --build . --config ${{ matrix.config }} --target binding-functions
37
+ if ((Get-Item "binding-functions").Length -lt 10) { $host.SetShouldExit(1) }
38
+
39
+ - name: Tests
40
+ working-directory: build
41
+ shell: cmd
42
+ env:
43
+ CTEST_OUTPUT_ON_FAILURE: 1
44
+ run: ctest -C ${{ matrix.config }}
@@ -58,12 +58,16 @@ env_docs/
58
58
  node_modules/
59
59
  website/dist/
60
60
  website/package-lock.json
61
+ website/.cache/
62
+ website/public/
61
63
  # Generated Doxyfile
62
64
  dev-docs/Doxyfile
63
65
 
64
66
  # CMake generated
65
67
  CMakeFiles
66
68
  CMakeCache.txt
69
+ CPackConfig.cmake
70
+ CPackSourceConfig.cmake
67
71
  Makefile
68
72
  cmake_install.cmake
69
73
  install_manifest.txt
@@ -90,6 +94,7 @@ coverage.cleaned.info
90
94
  *.cbp
91
95
  .idea
92
96
  .vscode
97
+ .ipynb_checkpoints
93
98
 
94
99
  # Generated by `make binding-functions`
95
100
  binding-functions