8000 `regexp` argument of `expect_warning()` unable to check for multiple warnings · Issue #2082 · r-lib/testthat · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
regexp argument of expect_warning() unable to check for multiple warnings #2082
Open
@3styleJam

Description

@3styleJam

While debugging some code I tried to call something like:

expect_warning(<insert expression here>, regexp = "apple|orange|lemon")

Expecting this to catch all the warnings that show up from the expression and contain one or more of the items, however instead e.g. for a warning that contains only apple, testthat will flag this twice when running through the tests because it doesn't find orange or lemon.

How would I fix this? Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0