Debian Codegraph @

addons/website_sale_slides/static/tests/tours/slides_course_member_invited_logged.js

raw symbols SCIP
1 import { registry } from "@web/core/registry";
2
3 registry.category("web_tour.tours").add("invited_on_payment_course_logged", {
4 steps: () => [
5 {
6 trigger: 'a:contains("Add to Cart")',
7 content: "Check that the course can be bought but not joined",
8 run: function () {
9 if (document.querySelector(".o_wslides_js_course_join_link")) {
10 console.error("The course should not be joinable before buying");
11 }
12 },
13 },
14 // Chatter is lazy loading. Wait for it.
15 {
16 trigger: "a[id=review-tab]",
17 run: "click",
18 },
19 {
20 content: "Wait for the whole page to load",
21 trigger: "#chatterRoot:shadow .o-mail-Chatter",
22 },
23 {
24 trigger: "a[id=home-tab]",
25 run: "click",
26 },
27 {
28 trigger: '.o_wslides_slides_list_slide:contains("Home Gardening")',
29 content: "Check that non-preview slides are not accessible",
30 run: function () {
31 if (this.anchor.querySelector(".o_wslides_js_slides_list_slide_link")) {
32 console.error("Invited attendee should not access non-preview slides");
33 }
34 },
35 },
36 {
37 trigger: 'a:contains("Gardening: The Know-How")',
38 content: "Check that preview slides are accessible",
39 },
40 ],
41 });