Skip to content

Cover entire pages with bUnit #468

Closed

Description

@SviatoslavK

I stumbled upon the weird problem with bUnit and am unsure if it is a bug or my misuse of bUnit. I'm doing a small integration test on a page. It looks something like this:

  • Find the button for adding a note on the page, click, make sure that a note appears on the page
  • Click on this note, and a sidebar should appear to edit it
  • Change note in the sidebar
  • Delete selected note
    For asynchronous actions, I use WaitForAssertion. And the problem is that the tests are written correctly, but they periodically crash without waiting for a timeout or not finding elements on the page. Perhaps this is because the rendering order of the components is different for different test runs? Or I won't be able to cover entire pages with tests using your library?

Version info:

  • bUnit version: 1.1.5
  • .NET 5, Blazor Server

Activity

  1. egil commented on Aug 3, 2021

    @egil
    Member

    Hi @SviatoslavK

    In general, a page in Blazor is just a component, so bUnit has no problem with that. What you are experiencing can be any number of things, so without a sample that reproduces the issue I cannot really help.

    Ill convert this to a discussion. If you have any additional info, please share it, and ill be happy to help more if I can.

  2. locked and limited conversation to collaborators on Aug 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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