Contributors mailing list archives

Browse archives


Very simple POS Tests go to backoffice

Disashop, Fernando La Chica
- 27/03/2023 17:39:19

I have a very simple test. It contains only two steps:

1º Wait for the loading to finish

    content: "Test pos_order_to_sale_order: Waiting for loading to finish",
    trigger: "body:not(:has(.loader))",
2º Click on the login button that appears because I have pos_hr installed.

    content: 'click login button',
    trigger: '.login-overlay',
    run: () => {}
Well, my Tour starts like any Tour for POS, visiting the URL "/pos/ui?config_id=X" where X is a pos_config. When it finishes loading, instead of showing the POS UI it goes to

I can see than first step succeeded Tour PosTicketActions: step 'Test pos_order_to_sale_order: Waiting for loading to finish (trigger: body:not(:has(.loader)))' succeeded

What seems very strange to me is that before the first step in the log it appears

Tour Manager is ready. running_tour=PosTicketActions

And just after the success and before executing the second step also appears the same message.

Tour Manager is ready. running_tour=PosTicketActions

It makes me think that for some reason, the "Ready" event of the Tour is fired in duplicate or that it doesn't clear the cache properly for some issue. As if I'm double subscribed to this event.

This URL is the one you go to when more than one POS tab is open. The second one visits the POS UI but the first one that stays in the background goes to the backoffice.

I have made sure that the user profiles and cookies are being removed from the headless that opens automatically when the start_tour is opened with watch=True. If I run the tests with watch=False the same thing happens, it leaves the POS UI and goes to Backoffice.