Running ‘aggregate.R’ [2s/2s]
  Comparing ‘aggregate.Rout’ to ‘aggregate.Rout.save’ ...4c4
< Linking to GEOS 3.6.2, GDAL 2.2.3, proj.4 5.0.0
---
> Linking to GEOS 3.5.1, GDAL 2.1.2, proj.4 4.9.3
  Running ‘cast.R’ [1s/2s]
  Comparing ‘cast.Rout’ to ‘cast.Rout.save’ ... OK
  Running ‘crs.R’ [1s/2s]
  Comparing ‘crs.Rout’ to ‘crs.Rout.save’ ...8c8,9
<   GDAL Error 6: EPSG PCS/GCS code -1 not found in EPSG support files.  Is this a valid EPSG coordinate system?
---
>   GDAL Error 6: EPSG PCS/GCS code -1 not found in EPSG support files.  Is this a valid
> EPSG coordinate system?
13c14,15
<   GDAL Error 6: EPSG PCS/GCS code 999999 not found in EPSG support files.  Is this a valid EPSG coordinate system?
---
>   GDAL Error 6: EPSG PCS/GCS code 999999 not found in EPSG support files.  Is this a valid
> EPSG coordinate system?
24c26
<   proj4string: "+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +towgs84=565.2369,50.0087,465.658,-0.406857,0.350733,-1.87035,4.0812 +units=m +no_defs"
---
>   proj4string: "+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +towgs84=565.4171,50.3319,465.5524,-0.398957,0.343988,-1.87740,4.0725 +units=m +no_defs"
65c67
< 1 °
---
> 1 arc_degree
  Running ‘dist.R’ [2s/3s]
  Comparing ‘dist.Rout’ to ‘dist.Rout.save’ ... OK
  Running ‘dplyr.R’ [8s/11s]
  Comparing ‘dplyr.Rout’ to ‘dplyr.Rout.save’ ...75c75
<   <fct>              <dbl>         <sf_geometry [degree]>
---
>   <fctr>             <dbl>         <sf_geometry [degree]>
157,158d156
< Warning message:
< 'person' is not a valid unit symbol recognized by udunits 
190,191c188,189
<            <[person/m^2]>              <sf_geometry [m]>
< 1 2.589362e-06 person/m^2 MULTIPOLYGON (((834893.7 95...
---
>   <units>                           <sf_geometry [m]>
> 1 2.58936155283424e-06 MULTIPOLYGON (((834893.7 95...
212,213c210,211
<            <[person]>              <sf_geometry [m]>
< 1       329962 person MULTIPOLYGON (((834893.7 95...
---
>   <units>                          <sf_geometry [m]>
> 1 329962              MULTIPOLYGON (((834893.7 95...
  Running ‘empty.R’ [1s/2s]
  Comparing ‘empty.Rout’ to ‘empty.Rout.save’ ... OK
  Running ‘gdal_geom.R’ [2s/3s]
  Comparing ‘gdal_geom.Rout’ to ‘gdal_geom.Rout.save’ ...100c100
< GDAL has 80 drivers
---
> GDAL has 77 drivers
273c273
< Error : cannot convert km into °
---
> Error : cannot convert km into arc_degrees
  Running ‘geos.R’ [11s/13s]
  Comparing ‘geos.Rout’ to ‘geos.Rout.save’ ... OK
  Running ‘graticule.R’ [6s/8s]
  Comparing ‘graticule.Rout’ to ‘graticule.Rout.save’ ... OK
  Running ‘grid.R’ [2s/3s]
  Comparing ‘grid.Rout’ to ‘grid.Rout.save’ ... OK
  Running ‘plot.R’ [10s/13s]
Running the tests in ‘tests/plot.R’ failed.
Complete output:
  > suppressPackageStartupMessages(library(sf))
  > library(dplyr)
  
  Attaching package: 'dplyr'
  
  The following objects are masked from 'package:stats':
  
      filter, lag
  
  The following objects are masked from 'package:base':
  
      intersect, setdiff, setequal, union
  
  > 
  > # plot linestrings:
  > l1 = st_linestring(matrix(runif(6)-0.5,,2))
  > l2 = st_linestring(matrix(runif(6)-0.5,,2))
  > l3 = st_linestring(matrix(runif(6)-0.5,,2))
  > s = st_sf(a=2:4, b=st_sfc(l1,l2,l3))
  > plot(s, col = s$a, axes = FALSE)
  > plot(s, col = s$a)
  > attr(s$b, "proj4string") = sp::CRS("+init=epsg:4326")@projargs
  > plot(s, col = s$a, axes = TRUE)
  > plot(s, col = s$a, lty = s$a, lwd = s$a, pch = s$a, type = 'b')
  > l4 = st_linestring(matrix(runif(6),,2))
  > plot(st_sf(a=1,b=st_sfc(l4)), add = TRUE)
  > # plot multilinestrings:
  > ml1 = st_multilinestring(list(l1, l2))
  > ml2 = st_multilinestring(list(l3, l4))
  > ml = st_sf(a = 2:3, b = st_sfc(ml1, ml2))
  > plot(ml, col = ml$a, lty = ml$a, lwd = ml$a, pch = ml$a, type = 'b')
  > # plot points:
  > p1 = st_point(c(1,2))
  > p2 = st_point(c(3,3))
  > p3 = st_point(c(3,0))
  > p = st_sf(a=2:4, b=st_sfc(p1,p2,p3))
  > plot(p, col = s$a, axes = TRUE)
  > plot(p, col = s$a)
  > plot(p, col = p$a, pch = p$a, cex = p$a, bg = s$a, lwd = 2, lty = 2, type = 'b')
  > p4 = st_point(c(2,2))
  > plot(st_sf(a=1, st_sfc(p4)), add = TRUE)
  > # multipoints:
  > mp1 = st_multipoint(matrix(1:4,2))
  > mp2 = st_multipoint(matrix(5:8,2))
  > mp = st_sf(a = 2:3, b = st_sfc(mp1, mp2))
  > plot(mp)
  Warning message:
  In classInt::classIntervals(na.omit(values), min(nbreaks, n.unq),  :
    n same as number of different finite values\neach different finite value is a separate class
  > plot(mp, col = mp$a, pch = mp$a, cex = mp$a, bg = mp$a, lwd = mp$a, lty = mp$a, type = 'b')
  > # polygon:
  > outer = matrix(c(0,0,10,0,10,10,0,10,0,0),ncol=2, byrow=TRUE)
  > hole1 = matrix(c(1,1,1,2,2,2,2,1,1,1),ncol=2, byrow=TRUE)
  > hole2 = matrix(c(5,5,5,6,6,6,6,5,5,5),ncol=2, byrow=TRUE)
  > pl1 = st_polygon(list(outer, hole1, hole2))
  > pl2 = st_polygon(list(outer+10, hole1+10, hole2+10))
  > po = st_sf(a = 2:3, st_sfc(pl1,pl2))
  > plot(po, col = po$a, border = rev(po$a), lwd=3)
  > # multipolygon
  > r10 = matrix(rep(c(0,10),each=5),5)
  > pl1 = list(outer, hole1, hole2)
  > pl2 = list(outer+10, hole1+10, hole2+10)
  > pl3 = list(outer+r10, hole1+r10, hole2+r10)
  > mpo1 = st_multipolygon(list(pl1,pl2))
  > mpo2 = st_multipolygon(list(pl3))
  > mpo = st_sf(a=2:3, b=st_sfc(mpo1,mpo2))
  > plot(mpo, col = mpo$a, border = rev(mpo$a), lwd = 2)
  > # geometrycollection:
  > gc1 = st_geometrycollection(list(mpo1, st_point(c(21,21)), l1 * 2 + 21))
  > gc2 = st_geometrycollection(list(mpo2, l2 - 2, l3 - 2, st_point(c(-1,-1))))
  > gc = st_sf(a=2:3, b = st_sfc(gc1,gc2))
  > plot(gc, cex = gc$a, col = gc$a, border = rev(gc$a) + 2, lwd = 2)
  > 
  > plot(gc1)
  > 
  > plot(st_sfc(mp1, mpo1))
  > 
  > # color ramp
  > nc = st_read(system.file("shape/nc.shp", package="sf"), quiet = TRUE)
  > plot(nc)
  Warning message:
  plotting the first 10 out of 14 attributes; use max.plot = 14 to plot all 
  > plot(nc, axes = TRUE)
  Warning message:
  plotting the first 10 out of 14 attributes; use max.plot = 14 to plot all 
  > plot(nc, col="lightgrey") 
  Warning message:
  plotting the first 10 out of 14 attributes; use max.plot = 14 to plot all 
  > plot(st_centroid(nc), add = TRUE, col = 1)
  Warning messages:
  1: In st_centroid.sfc(st_geometry(x), of_largest_polygon = of_largest_polygon) :
    st_centroid does not give correct centroids for longitude/latitude data
  2: In plot.sf(st_centroid(nc), add = TRUE, col = 1) :
    ignoring all but the first attribute
  > nc %>% 
  +   select(geometry) %>% 
  +   plot()
  > 
  > nc$f = cut(nc[[1]], 5)
  > plot(nc["f"], key.pos = 1)
  > plot(nc[1],   key.pos = 1)
  > 
  > # test background map plotting:
  > data(bgmap)
  > merc = st_crs(3857)
  > WGS84 = st_crs(4326)
  > nc = st_transform(nc, WGS84)
  > ## ggmap:
  > #library(ggmap)
  > #bgMap = get_map(unname(st_bbox(nc)), source = "google", zoom = 8) 
  > plot(st_transform(nc[1], merc), bgMap = bgMap)
  > 
  > # RgoogleMaps:
  > #library(RgoogleMaps)
  > #center = c(mean(st_bbox(nc)[c(2,4)]), mean(st_bbox(nc)[c(1,3)]))
  > #g = GetMap(center=center, zoom=6) # google
  > par(mar = c(0,0,1,0))
  > plot(st_transform(nc, merc), bgMap = g)
  Warning message:
  plotting the first 10 out of 15 attributes; use max.plot = 15 to plot all 
  > 
  > m = st_make_grid()
  > st_crs(m) = NA_crs_
  > m = st_segmentize(m, 2)
  > st_crs(m) = 4326
  > plot(m, axes = TRUE)
  > g = st_transform(m, st_crs("+proj=ortho +lat_0=30 +lon_0=45"), check = TRUE)
  > plot(g, axes = TRUE)
  Error in CPL_geos_is_empty(st_geometry(x)) : 
    Evaluation error: IllegalArgumentException: Invalid number of points in LinearRing found 3 - must be 0 or >= 4.
  Calls: plot ... plot.sfc_POLYGON -> st_is_empty -> CPL_geos_is_empty -> .Call
  Execution halted