Skip to content

expect_snapshot() fails when names contain backquotes #1780

Open
@moodymudskipper

Description

@moodymudskipper

When running such test:

test_that("backquotes", {
  expect_snapshot(
    c("`a`" = 1)
  )
})

I get :

`c(`\`a\`` = 2)` threw an unexpected error.
Message: attempt to use zero-length variable name
Class:   simpleError/error/condition

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugan unexpected problem or unintended behaviorsnapshot 📷

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions