Skip to content

Commit

Permalink
update snaps
Browse files Browse the repository at this point in the history
  • Loading branch information
jdhoffa committed Feb 20, 2024
1 parent 68976bb commit 3b74227
Showing 1 changed file with 15 additions and 8 deletions.
23 changes: 15 additions & 8 deletions tests/testthat/_snaps/plot_emission_intensity.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,33 @@
# if `data` is not a data frame errors gracefully

is.data.frame(data) is not TRUE
rlang::is_named(data) is not TRUE

# if `data` is not sda-like errors gracefully

`data` must have all the expected names.
x Missing names: emission_factor_metric, emission_factor_value.
x Missing names: emission_factor_metric, emission_factor_value, label.
i Is your data `sda`-like?
Caused by error in `abort_if_missing_names()`:
! `data` must have all the expected names.
x Missing names: emission_factor_metric, emission_factor_value.
x Missing names: emission_factor_metric, emission_factor_value, label.

# if `data` has zero rows errors gracefully

`zero_row` must have some rows.
x `zero_row` has zero rows.
`data` must have all the expected names.
x Missing names: label.
i Is your data `sda`-like?
Caused by error in `abort_if_missing_names()`:
! `data` must have all the expected names.
x Missing names: label.

# with too many sectors errors gracefully

`data` must have a single value of `sector`.
i Do you need to pick one value? E.g. pick 'a' with: `subset(data, sector == 'a')`.
x Provided: a, b.
`data` must have all the expected names.
x Missing names: label.
i Is your data `sda`-like?
Caused by error in `abort_if_missing_names()`:
! `data` must have all the expected names.
x Missing names: label.

# with too many lines to plot errors gracefully

Expand Down

0 comments on commit 3b74227

Please sign in to comment.