Skip to content

Commit

Permalink
test wrong blk
Browse files Browse the repository at this point in the history
  • Loading branch information
joethorley committed Oct 26, 2024
1 parent cfed0d3 commit d7af69a
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
blk,old_rm,extra,stream_measure,distance_to_stream
356308001,0,1,0,2068.718359844097
356308001,500,2,0,1582.4862323952286
356308001,1000,3,53.261053,1092.886374560971
356308001,1500,4,18.92421,594.2001865485568
356308001,2000,5,0,98.0373252071289
356308001,2500,6,0,395.5152937303073
356308001,3000,7,0,885.5021687843321
356308001,3500,8,0,1382.134716892469
356308001,0,9,0,0
356308001,500,10,500,5.02333254310528e-11
356308001,1000,11,1000,4.4919518690793016e-11
356308001,1500,12,1500,1.4497171512980975e-11
356308001,2000,13,2000,9.970664902722507e-11
356308001,2500,14,2500,1.3193441948615151e-11
356308001,3000,15,3000,2.946326656182626e-12
356308001,3500,16,3500,4.108499628932751e-11
356308001,4000,17,4000,4.787735991540772e-11
356308001,4500,18,4500,1.3062015680722343e-10
356308001,5000,19,5000,1.7527570006745085e-11
356308001,5500,20,5500,3.104044292606418e-11
356308001,6000,21,6000,3.1178206447063644e-11
356308001,6500,22,6500,4.370329563308768e-11
356308001,7000,23,7000,2.8759291842977808e-11
356308001,7500,24,7500,3.36427837864163e-11
356308001,8000,25,8000,3.103063097437563e-11
356308001,8500,26,8500,4.733875176184733e-11
356308001,9000,27,9000,5.329983057120898e-12
356308001,9500,28,9500,8.74698478602545e-11
356308001,10000,29,10000,4.202214849497567e-11
356308001,10500,30,10500,3.159595675670876e-12
356308001,11000,31,11000,1.1834616756984147e-10
356308001,11500,32,11500,4.5760118661185163e-11
356308001,12000,33,12000,1.1287946131829215e-10
356308001,12500,34,12500,1.5213397107487046e-11
356308001,13000,35,13000,3.476779582005125e-11
356308001,13500,36,13500,1.657516551712718e-11
356308001,14000,37,14000,9.953290368283257e-11
356308001,14500,38,14500,8.575522974562711e-12
356308001,15000,39,15000,4.05857384434626e-11
356308001,15500,40,15500,2.7084545102022772e-11
356308001,16000,41,16000,3.150769070332575e-11
356308001,16500,42,16500,7.110779405087932e-11
356308001,17000,43,17000,1.0100291250045592e-10
356308001,17500,44,17500,3.445288675090671e-11
356308001,18000,45,18000,4.619865631998603e-11
356308001,18500,46,18500,4.25866702396408e-12
356308001,19000,47,19000,1.2706624081981968e-11
7 changes: 7 additions & 0 deletions tests/testthat/test-snap-stream-measure-to-point.R
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,11 @@ test_that("fwa_snap_stream_measure_to_point", {
stream_measure_no_blk_off <- fwa_snap_stream_measure_to_point(points_no_blk_off, streams)
expect_identical(nrow(stream_measure_no_blk_off), nrow(points))
expect_snapshot_data(stream_measure_no_blk_off, "stream_measure_no_blk_off")

points_blk_diff <- points
points_blk_diff$blk[points_blk_diff$blk == 355992255] <- 356308001

stream_measure_blk_diff <- fwa_snap_stream_measure_to_point(points_blk_diff, streams)
expect_identical(nrow(stream_measure_blk_diff), nrow(points))
expect_snapshot_data(stream_measure_blk_diff, "stream_measure_blk_diff")
})

0 comments on commit d7af69a

Please sign in to comment.