You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by hn...@apache.org on 2024/12/13 09:29:50 UTC

(myfaces-tobago) branch main updated: test: exist: tobago-header/tobago-footer

This is an automated email from the ASF dual-hosted git repository.

hnoeth pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git


The following commit(s) were added to refs/heads/main by this push:
     new 9be270fed8 test: exist: tobago-header/tobago-footer
9be270fed8 is described below

commit 9be270fed84f9ca7d98edf94ac7e43a597e815d7
Author: Henning Noeth <hn...@apache.org>
AuthorDate: Fri Dec 13 10:18:13 2024 +0100

    test: exist: tobago-header/tobago-footer
---
 .../tobago-example-demo/src/main/webapp/script/tobago-test.js     | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/tobago-example/tobago-example-demo/src/main/webapp/script/tobago-test.js b/tobago-example/tobago-example-demo/src/main/webapp/script/tobago-test.js
index ece78b9e93..1be6d4f88e 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/script/tobago-test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/script/tobago-test.js
@@ -95,4 +95,12 @@ describe("general", function () {
 
     expect(result.indexOf("???")).toBeLessThanOrEqual(-1, "There must no '???' on the site.");
   });
+
+  it("If there is a tobago-header it must be a tobago-footer", function () {
+    const header = querySelectorFn("tobago-page > form > tobago-header")();
+    const footer = querySelectorFn("tobago-page > form > tobago-footer")();
+    const headerExist = header != null;
+    const footerExist = footer != null;
+    expect(headerExist).toBe(footerExist);
+  });
 });