Wunderbyte-GmbH / moodle-mod_booking

Moodle Booking Module
https://www.wunderbyte.at
21 stars 38 forks source link

Behat test for new feature cancel bought item #454

Open georgmaisser opened 4 months ago

georgmaisser commented 4 months ago

A bought item can now be canceled not only via shopping cart history, but directly from booking.

Please write a behat test for this feature:

https://github.com/Wunderbyte-GmbH/moodle-mod_booking/pull/453

The differences in the modal come from the different quota consumed logic set in the booking options.

https://github.com/Wunderbyte-GmbH/moodle-mod_booking/assets/7524621/b52f8710-2b5a-4d2d-8021-ddbea017c912

semteacher commented 4 months ago

Have installed dev_401 branches of shopping_cart, bookinf and wb_table. No modal, cancellation not processed. No errors.

Image

Colud it be the problem that dates are in the past? But I was allowed to book (as admin)

semteacher commented 4 months ago
  1. Above solved by editing each booking option - too old DB with no json data for booking option. Hovewer, this could indicate a potential issues with continuous upgrading process (eligible json value had to be created at some particular step when new features were introduced)
  2. How purcase could be made if no shopping_cart installed? It not mandatory and not listed to install for tests at GitHub
semteacher commented 3 months ago

It looks like that to complete behat test - no other way than have shopping_cart installed. Even if I override and instantiate booking answer via DB - at least "shopping_cart histiry" table required....

Image

If shopping cart not being installed - "cancelmyself" not applied at all

Image

semteacher commented 2 months ago

@georgmaisser Task is complete except "The differences in the modal come from the different quota consumed logic set in the booking options." Sorry cannot exactly takes differences (even with video). What settings and where have to be customized?