test_that("phf_team_box", {
skip_on_cran()
skip_on_ci()
cols <- c(
"team",
"game_id",
"winner",
"total_scoring",
"successful_power_play",
"power_play_opportunities",
"power_play_percent",
"penalty_minutes",
"faceoff_percent",
"blocked_opponent_shots",
"takeaways",
"giveaways",
"period_1_shots",
"period_2_shots",
"period_3_shots",
"overtime_shots",
"shootout_made_shots",
"shootout_missed_shots",
"total_shots",
"period_1_scoring",
"period_2_scoring",
"period_3_scoring",
"overtime_scoring",
"shootout_made_scoring",
"shootout_missed_scoring"
)
x <- phf_team_box(game_id = 40863)
y <- phf_team_box(game_id = 268079)
expect_equal(colnames(x), cols)
expect_equal(colnames(y), cols)
expect_s3_class(x, "data.frame")
expect_s3_class(y, "data.frame")
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.