Skip to content

Commit

Permalink
additional #1185 test for rowwise
Browse files Browse the repository at this point in the history
  • Loading branch information
romainfrancois committed Apr 9, 2018
1 parent a2b2510 commit ea6db02
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/testthat/test-group-indices.R
Expand Up @@ -44,4 +44,10 @@ test_that("group_indices() can be used inside mutate (#1185)", {
pull(mutate(df, g = group_indices())),
rep(0L, 6)
)

df <- data_frame(v1 = c(3, 3, 2, 2, 3, 1), v2 = 1:6)
expect_identical(
pull(mutate(rowwise(df), g = group_indices())),
1:6
)
})

0 comments on commit ea6db02

Please sign in to comment.