myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lof...@apache.org
Subject [myfaces-tobago] 02/02: TOBAGO-1902: Migrate to jQuery 3
Date Thu, 21 Jun 2018 12:34:15 GMT
This is an automated email from the ASF dual-hosted git repository.

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

commit 9627178bfa16699b9857282521bf566e6ae8dd82
Author: Udo Schnurpfeil <lofwyr@apache.org>
AuthorDate: Thu Jun 21 14:33:57 2018 +0200

    TOBAGO-1902: Migrate to jQuery 3
    
    Preparation:
    * compatibel changes (resp. jQuery 2.2.4)
    ** remove .selector
    ** replace .size() with .length
---
 .../20-component/010-input/10-in/in.test.js        |   4 +-
 .../010-input/20-suggest/suggest.test.js           | 208 +++++----
 .../20-component/010-input/40-date/date.test.js    |  14 +-
 .../selectBooleanCheckbox.test.js                  |  40 +-
 .../20-selectOneChoice/selectOneChoice.test.js     |  12 +-
 .../30-selectOneRadio/selectOneRadio.test.js       |  12 +-
 .../40-selectOneListbox/selectOneListbox.test.js   |  12 +-
 .../selectManyCheckbox.test.js                     |  16 +-
 .../content/20-component/060-popup/popup.test.js   |  96 ++--
 .../080-sheet/10-sort/sheet-sorting.test.js        | 378 ++++++++--------
 .../080-sheet/30-event/sheet-event.test.js         | 146 +++---
 .../090-tree/01-select/tree-select.test.js         | 208 +++++----
 .../06-validation/00/content-validation.test.js    | 146 +++---
 .../06-validation/01/validation-jsr303.test.js     |  35 +-
 .../08-form/10-required/form-required.test.js      |  26 +-
 .../30-concept/08-form/20-ajax/form-ajax.test.js   | 504 +++++++++++----------
 .../webapp/content/30-concept/08-form/form.test.js |   4 +-
 .../30-concept/51-for-each/for-each.test.js        |  51 ++-
 .../00-collapsible-box/collapsible-box.test.js     | 239 +++++-----
 .../10-collapsible-popup/collapsible-popup.test.js | 116 +++--
 .../20-collapsible-panel/collapsible-panel.test.js | 246 +++++-----
 .../collapsible-section.test.js                    | 216 +++++----
 .../15-suggest-method/suggest-method.test.js       |  14 +-
 .../40-test/4000-button+link/button+link.test.js   |  44 +-
 .../20-ajax-execute/ajax-execute.test.js           |  73 +--
 .../ajax-special-character.test.js                 |  21 +-
 .../content/40-test/6000-event/event.test.js       |   6 +-
 .../src/main/webapp/script/tobago-test.js          |   5 +-
 .../src/main/webapp/test/version/version.js        |   6 +-
 .../resources/tobago/standard/script/tobago.js     |   2 +-
 30 files changed, 1557 insertions(+), 1343 deletions(-)

diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/10-in/in.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/10-in/in.test.js
index 5332c17..a15a21a 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/10-in/in.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/10-in/in.test.js
@@ -40,10 +40,10 @@ QUnit.test("ajax change event", function (assert) {
   assert.equal($inputField.val(), "qwe");
 
   waitForAjax(function () {
-    $outputField = jQueryFrame($outputField.selector);
+    $outputField = jQueryFrame("#page\\:mainForm\\:outputAjax span:first");
     return $outputField.text() == "qwe";
   }, function () {
-    $outputField = jQueryFrame($outputField.selector);
+    $outputField = jQueryFrame("#page\\:mainForm\\:outputAjax span:first");
     assert.equal($outputField.text(), "qwe");
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/20-suggest/suggest.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/20-suggest/suggest.test.js
index a3f20df..9028dac 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/20-suggest/suggest.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/20-suggest/suggest.test.js
@@ -23,18 +23,18 @@ QUnit.test("Basics: 'C'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -51,18 +51,18 @@ QUnit.test("Basics: 'Ch'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -78,18 +78,18 @@ QUnit.test("Basics: 'Chi'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -105,18 +105,18 @@ QUnit.test("Basics: 'Chil'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -132,18 +132,18 @@ QUnit.test("Basics: 'Chile'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -159,18 +159,18 @@ QUnit.test("Basics: 'Chile '", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -186,18 +186,18 @@ QUnit.test("Basics: 'Chile ('", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -213,18 +213,18 @@ QUnit.test("Basics: 'Chile (e'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -240,18 +240,18 @@ QUnit.test("Basics: 'Chile (es'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -267,18 +267,18 @@ QUnit.test("Basics: 'Chile (esp'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -294,18 +294,18 @@ QUnit.test("Basics: 'Chile (espa'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -321,18 +321,18 @@ QUnit.test("Basics: 'Chile (espan'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -348,18 +348,18 @@ QUnit.test("Basics: 'Chile (espanj'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -375,18 +375,18 @@ QUnit.test("Basics: 'Chile (espanja'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -402,18 +402,18 @@ QUnit.test("Basics: 'Chile (espanja)'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == expectedLength;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === expectedLength;
   }, function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
 
     assert.equal($suggestions.length, expectedLength);
-    for (i = 0; i < expectedLength; i++) {
+    for (var i = 0; i < expectedLength; i++) {
       assert.ok($suggestions.eq(i).find("strong").text().toUpperCase().indexOf(inputString.toUpperCase()) >= 0);
     }
 
@@ -426,22 +426,23 @@ QUnit.test("Basics: Add 'Belgiu' and click first entry.", function(assert) {
   var done = assert.async();
 
   assert.equal(1, 1);
-  var $in = jQueryFrame("#page\\:mainForm\\:inBasic\\:\\:field");
+  var inSelector = "#page\\:mainForm\\:inBasic\\:\\:field";
+  var $in = jQueryFrame(inSelector);
   assert.equal(1, 1);
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inBasic");
+  var $suggestions = getSuggestionsInBasic();
   assert.equal(1, 1);
 
   $in.val("Belgiu").trigger('input');
   assert.equal($in.val(), "Belgiu");
 
   waitForAjax(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
-    return $suggestions.length == 2;
+    $suggestions = getSuggestionsInBasic();
+    return $suggestions.length === 2;
   }, function() {
     assert.equal(1, 1);
-    $in = jQueryFrame($in.selector);
+    $in = jQueryFrame(inSelector);
     assert.equal(1, 1);
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInBasic();
     assert.equal(1, 1);
 
     assert.equal($suggestions.length, 2);
@@ -462,17 +463,17 @@ QUnit.test("Advanced: 'H'", function(assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:inAdvanced\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inAdvanced");
+  var $suggestions = getSuggestionsInAdvanced();
   var suggestionDelay = 2000;
 
   $in.val("H").trigger('input');
 
   setTimeout(function() {
     waitForAjax(function() {
-      $suggestions = jQueryFrame($suggestions.selector);
-      return $suggestions.length == 0;
+      $suggestions = getSuggestionsInAdvanced();
+      return $suggestions.length === 0;
     }, function() {
-      $suggestions = jQueryFrame($suggestions.selector);
+      $suggestions = getSuggestionsInAdvanced();
       assert.equal($suggestions.length, 0);
       done();
     });
@@ -483,14 +484,15 @@ QUnit.test("Advanced: 'Ho'", function(assert) {
   assert.expect(4);
   var done = assert.async(2);
 
-  var $in = jQueryFrame("#page\\:mainForm\\:inAdvanced\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inAdvanced");
+  var inSelector = "#page\\:mainForm\\:inAdvanced\\:\\:field";
+  var $in = jQueryFrame(inSelector);
+  var $suggestions = getSuggestionsInAdvanced();
   var suggestionDelay = 2000;
 
   $in.val("Ho").trigger('input');
 
   setTimeout(function() {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestionsInAdvanced();
 
     // Nothing happen, because the delay is greater than the default delay.
     assert.equal($suggestions.length, 0);
@@ -500,15 +502,15 @@ QUnit.test("Advanced: 'Ho'", function(assert) {
 
   setTimeout(function() {
     waitForAjax(function() {
-      $in = jQueryFrame($in.selector);
-      $suggestions = jQueryFrame($suggestions.selector);
+      $in = jQueryFrame(inSelector);
+      $suggestions = getSuggestionsInAdvanced();
 
-      return $suggestions.length == 2
-          && $suggestions.eq(0).find("strong").text() == "ho"
-          && $suggestions.eq(1).find("strong").text() == "ho";
+      return $suggestions.length === 2
+          && $suggestions.eq(0).find("strong").text() === "ho"
+          && $suggestions.eq(1).find("strong").text() === "ho";
     }, function() {
-      $in = jQueryFrame($in.selector);
-      $suggestions = jQueryFrame($suggestions.selector);
+      $in = jQueryFrame(inSelector);
+      $suggestions = getSuggestionsInAdvanced();
 
       assert.equal($suggestions.length, 2);
       assert.equal($suggestions.eq(0).find("strong").text(), "ho");
@@ -523,11 +525,11 @@ QUnit.test("Client sided: 'Korean'", function(assert) {
   assert.expect(5);
 
   var $in = jQueryFrame("#page\\:mainForm\\:inClient\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:inClient");
+  var $suggestions = getSuggestionsInClient();
 
   $in.val("Korean").trigger('input');
 
-  $suggestions = jQueryFrame($suggestions.selector);
+  $suggestions = getSuggestionsInClient();
   assert.equal($suggestions.length, 4);
   assert.equal($suggestions.eq(0).find("strong").text(), "Korean");
   assert.equal($suggestions.eq(1).find("strong").text(), "Korean");
@@ -535,6 +537,18 @@ QUnit.test("Client sided: 'Korean'", function(assert) {
   assert.equal($suggestions.eq(3).find("strong").text(), "Korean");
 });
 
+function getSuggestionsInBasic() {
+  return getSuggestions("#page\\:mainForm\\:inBasic")
+}
+
+function getSuggestionsInAdvanced() {
+  return getSuggestions("#page\\:mainForm\\:inAdvanced")
+}
+
+function getSuggestionsInClient() {
+  return getSuggestions("#page\\:mainForm\\:inClient");
+}
+
 function getSuggestions(id) {
   return jQueryFrame(Tobago.Utils.escapeClientId(
           jQueryFrame(id + " .tobago-suggest").attr("id") + "::popup") + " .tt-suggestion");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/40-date/date.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/40-date/date.test.js
index b4cfbb0..6793258 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/40-date/date.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/010-input/40-date/date.test.js
@@ -61,11 +61,11 @@ QUnit.test("submit", function(assert) {
   assert.ok(jQueryFrame(".bootstrap-datetimepicker-widget").get(0),
       ".bootstrap-datetimepicker-widget should be available");
 
-  $days = jQueryFrame($days.selector);
+  $days = jQueryFrame(".bootstrap-datetimepicker-widget .day");
   var day22 = 0;
   for (i = 0; i < $days.length; i++) {
-    $days = jQueryFrame($days.selector);
-    if ($days.eq(i).text() == "22") {
+    $days = jQueryFrame(".bootstrap-datetimepicker-widget .day");
+    if ($days.eq(i).text() === "22") {
       day22 = i;
       break;
     }
@@ -76,7 +76,7 @@ QUnit.test("submit", function(assert) {
   assert.equal($dateField.val(), "01.06.2016");
   $submitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $outField = jQueryFrame("#page\\:mainForm\\:formSubmit\\:output span");
     assert.equal($outField.text(), "01.06.2016");
     done();
@@ -101,10 +101,10 @@ QUnit.test("ajax", function (assert) {
   assert.equal($dateField.val(), today);
 
   waitForAjax(function () {
-    $outField = jQueryFrame($outField.selector);
-    return $outField.text() == today;
+    $outField = jQueryFrame("#page\\:mainForm\\:outputfield span");
+    return $outField.text() === today;
   }, function () {
-    $outField = jQueryFrame($outField.selector);
+    $outField = jQueryFrame("#page\\:mainForm\\:outputfield span");
     assert.equal($outField.text(), today);
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/10-selectBooleanCheckbox/selectBooleanCheckbox.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/10-selectBooleanCheckbox/selectBooleanCheckbox.test.js
index 00671aa..592e8d3 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/10-selectBooleanCheckbox/selectBooleanCheckbox.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/10-selectBooleanCheckbox/selectBooleanCheckbox.test.js
@@ -28,7 +28,7 @@ QUnit.test("submit: select A", function (assert) {
   $selectC.prop("checked", false);
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:submitOutput span");
     assert.equal($output.text(), "A ");
     done();
@@ -48,7 +48,7 @@ QUnit.test("submit: select B and C", function (assert) {
   $selectC.prop("checked", true);
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:submitOutput span");
     assert.equal($output.text(), "B C ");
     done();
@@ -64,10 +64,10 @@ QUnit.test("ajax: select D", function (assert) {
   $selectD.prop("checked", true).trigger("change");
 
   waitForAjax(function () {
-    $outputD = jQueryFrame($outputD.selector);
-    return $outputD.text() == "true";
+    $outputD = jQueryFrame("#page\\:mainForm\\:outputD span");
+    return $outputD.text() === "true";
   }, function () {
-    $outputD = jQueryFrame($outputD.selector);
+    $outputD = jQueryFrame("#page\\:mainForm\\:outputD span");
     assert.equal($outputD.text(), "true");
     done();
   });
@@ -82,10 +82,10 @@ QUnit.test("ajax: deselect D", function (assert) {
   $selectD.prop("checked", false).trigger("change");
 
   waitForAjax(function () {
-    $outputD = jQueryFrame($outputD.selector);
-    return $outputD.text() == "false";
+    $outputD = jQueryFrame("#page\\:mainForm\\:outputD span");
+    return $outputD.text() === "false";
   }, function () {
-    $outputD = jQueryFrame($outputD.selector);
+    $outputD = jQueryFrame("#page\\:mainForm\\:outputD span");
     assert.equal($outputD.text(), "false");
     done();
   });
@@ -100,10 +100,10 @@ QUnit.test("ajax: select E", function (assert) {
   $selectE.prop("checked", true).trigger("change");
 
   waitForAjax(function () {
-    $outputE = jQueryFrame($outputE.selector);
-    return $outputE.text() == "true";
+    $outputE = jQueryFrame("#page\\:mainForm\\:outputE span");
+    return $outputE.text() === "true";
   }, function () {
-    $outputE = jQueryFrame($outputE.selector);
+    $outputE = jQueryFrame("#page\\:mainForm\\:outputE span");
     assert.equal($outputE.text(), "true");
     done();
   });
@@ -118,10 +118,10 @@ QUnit.test("ajax: deselect E", function (assert) {
   $selectE.prop("checked", false).trigger("change");
 
   waitForAjax(function () {
-    $outputE = jQueryFrame($outputE.selector);
-    return $outputE.text() == "false";
+    $outputE = jQueryFrame("#page\\:mainForm\\:outputE span");
+    return $outputE.text() === "false";
   }, function () {
-    $outputE = jQueryFrame($outputE.selector);
+    $outputE = jQueryFrame("#page\\:mainForm\\:outputE span");
     assert.equal($outputE.text(), "false");
     done();
   });
@@ -136,10 +136,10 @@ QUnit.test("ajax: select F", function (assert) {
   $selectF.prop("checked", true).trigger("change");
 
   waitForAjax(function () {
-    $outputF = jQueryFrame($outputF.selector);
-    return $outputF.text() == "true";
+    $outputF = jQueryFrame("#page\\:mainForm\\:outputF span");
+    return $outputF.text() === "true";
   }, function () {
-    $outputF = jQueryFrame($outputF.selector);
+    $outputF = jQueryFrame("#page\\:mainForm\\:outputF span");
     assert.equal($outputF.text(), "true");
     done();
   });
@@ -154,10 +154,10 @@ QUnit.test("ajax: deselect F", function (assert) {
   $selectF.prop("checked", false).trigger("change");
 
   waitForAjax(function () {
-    $outputF = jQueryFrame($outputF.selector);
-    return $outputF.text() == "false";
+    $outputF = jQueryFrame("#page\\:mainForm\\:outputF span");
+    return $outputF.text() === "false";
   }, function () {
-    $outputF = jQueryFrame($outputF.selector);
+    $outputF = jQueryFrame("#page\\:mainForm\\:outputF span");
     assert.equal($outputF.text(), "false");
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/20-selectOneChoice/selectOneChoice.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/20-selectOneChoice/selectOneChoice.test.js
index d1cc277..1613ed6 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/20-selectOneChoice/selectOneChoice.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/20-selectOneChoice/selectOneChoice.test.js
@@ -26,7 +26,7 @@ QUnit.test("submit: Alice", function (assert) {
   $bob.prop("selected", false);
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:outputPerson span");
     assert.equal($output.text(), "Alice Anderson");
     done();
@@ -44,7 +44,7 @@ QUnit.test("submit: Bob", function (assert) {
   $bob.prop("selected", true);
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:outputPerson span");
     assert.equal($output.text(), "Bob Brunch");
     done();
@@ -62,11 +62,11 @@ QUnit.test("ajax: select Mars", function (assert) {
   $mars.prop("selected", true).trigger("change");
 
   waitForAjax(function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonbox\\:\\:field option");
     return $moons.eq(0).text() == "Phobos"
         && $moons.eq(1).text() == "Deimos";
   }, function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonbox\\:\\:field option");
     assert.equal($moons.eq(0).text(), "Phobos");
     assert.equal($moons.eq(1).text(), "Deimos");
     done();
@@ -84,13 +84,13 @@ QUnit.test("ajax: select Jupiter", function (assert) {
   $jupiter.prop("selected", true).trigger("change");
 
   waitForAjax(function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonbox\\:\\:field option");
     return $moons.eq(0).text() == "Europa"
         && $moons.eq(1).text() == "Ganymed"
         && $moons.eq(2).text() == "Io"
         && $moons.eq(3).text() == "Kallisto";
   }, function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonbox\\:\\:field option");
     assert.equal($moons.eq(0).text(), "Europa");
     assert.equal($moons.eq(1).text(), "Ganymed");
     assert.equal($moons.eq(2).text(), "Io");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/30-selectOneRadio/selectOneRadio.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/30-selectOneRadio/selectOneRadio.test.js
index d68d8d8..13b7d2d 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/30-selectOneRadio/selectOneRadio.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/30-selectOneRadio/selectOneRadio.test.js
@@ -30,7 +30,7 @@ QUnit.test("submit: Addition (2 + 4)", function (assert) {
   $number2.eq(2).prop("checked", true); // Select 4
   $submitAdd.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     assert.equal($output.text(), "6");
     done();
@@ -52,7 +52,7 @@ QUnit.test("submit: Subtraction (4 - 1)", function (assert) {
   $number2.eq(2).prop("checked", false);
   $submitSub.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     assert.equal($output.text(), "3");
     done();
@@ -70,11 +70,11 @@ QUnit.test("ajax: select Mars", function (assert) {
   $planet.eq(1).prop("checked", true).trigger("change"); // Mars.
 
   waitForAjax(function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonradio li label");
     return $moons.eq(0).text() == "Phobos"
         && $moons.eq(1).text() == "Deimos";
   }, function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonradio li label");
     assert.equal($moons.eq(0).text(), "Phobos");
     assert.equal($moons.eq(1).text(), "Deimos");
     done();
@@ -92,13 +92,13 @@ QUnit.test("ajax: select Jupiter", function (assert) {
   $planet.eq(2).prop("checked", true).trigger("change"); // Jupiter.
 
   waitForAjax(function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonradio li label");
     return $moons.eq(0).text() == "Europa"
         && $moons.eq(1).text() == "Ganymed"
         && $moons.eq(2).text() == "Io"
         && $moons.eq(3).text() == "Kallisto";
   }, function () {
-    $moons = jQueryFrame($moons.selector);
+    $moons = jQueryFrame("#page\\:mainForm\\:moonradio li label");
     assert.equal($moons.eq(0).text(), "Europa");
     assert.equal($moons.eq(1).text(), "Ganymed");
     assert.equal($moons.eq(2).text(), "Io");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/40-selectOneListbox/selectOneListbox.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/40-selectOneListbox/selectOneListbox.test.js
index b3ddbfa..c52faf4 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/40-selectOneListbox/selectOneListbox.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/40-selectOneListbox/selectOneListbox.test.js
@@ -28,7 +28,7 @@ QUnit.test("submit: select 'Nile'", function (assert) {
   $rivers.eq(4).prop("selected", false); // ParanĂ¡ River
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:riverOutput span");
     assert.equal($output.text(), "6853 km");
     done();
@@ -48,7 +48,7 @@ QUnit.test("submit: select 'Yangtze'", function (assert) {
   $rivers.eq(4).prop("selected", false); // ParanĂ¡ River
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:riverOutput span");
     assert.equal($output.text(), "6300 km");
     done();
@@ -68,10 +68,10 @@ QUnit.test("ajax: select Everest", function (assert) {
   $mountains.eq(0).prop("selected", true).trigger("change"); // Everest
 
   waitForAjax(function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:selectedMountain span");
     return $output.text() == "8848 m";
   }, function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:selectedMountain span");
     assert.equal($output.text(), "8848 m");
     done();
   });
@@ -90,10 +90,10 @@ QUnit.test("ajax: select Makalu", function (assert) {
   $mountains.eq(4).prop("selected", true).trigger("change"); // Everest
 
   waitForAjax(function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:selectedMountain span");
     return $output.text() == "8481 m";
   }, function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:selectedMountain span");
     assert.equal($output.text(), "8481 m");
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/50-selectManyCheckbox/selectManyCheckbox.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/50-selectManyCheckbox/selectManyCheckbox.test.js
index 1beaace..f521f1c 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/50-selectManyCheckbox/selectManyCheckbox.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/030-select/50-selectManyCheckbox/selectManyCheckbox.test.js
@@ -27,7 +27,7 @@ QUnit.test("submit: select cat", function (assert) {
   $animals.eq(3).prop("checked", false);
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:animalsOutput span");
     assert.equal($output.text(), "Cat ");
     done();
@@ -46,7 +46,7 @@ QUnit.test("submit: select fox and rabbit", function (assert) {
   $animals.eq(3).prop("checked", true);
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     var $output = jQueryFrame("#page\\:mainForm\\:animalsOutput span");
     assert.equal($output.text(), "Fox Rabbit ");
     done();
@@ -70,10 +70,10 @@ QUnit.test("ajax: click 'Two'", function (assert) {
   }
 
   waitForAjax(function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     return $output.text() == newOutputValue;
   }, function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     assert.equal($output.text(), newOutputValue);
     done();
   });
@@ -96,10 +96,10 @@ QUnit.test("ajax: click 'Three'", function (assert) {
   }
 
   waitForAjax(function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     return $output.text() == newOutputValue;
   }, function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     assert.equal($output.text(), newOutputValue);
     done();
   });
@@ -122,10 +122,10 @@ QUnit.test("ajax: click 'Two'", function (assert) {
   }
 
   waitForAjax(function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     return $output.text() == newOutputValue;
   }, function () {
-    $output = jQueryFrame($output.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:resultOutput span");
     assert.equal($output.text(), newOutputValue);
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/060-popup/popup.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/060-popup/popup.test.js
index a0875f0..d9edf07 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/060-popup/popup.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/060-popup/popup.test.js
@@ -27,18 +27,18 @@ QUnit.test("Open 'Simple Popup' and press 'Cancel'.", function(assert) {
   assert.equal($popup.attr("value"), "true");
   $openButton.click();
 
-  jQuery("#page\\:testframe").load(function() {
+  jQuery("#page\\:testframe").on("load", function() {
     if (step == 1) {
-      $popup = jQueryFrame($popup.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
       assert.equal($popup.attr("value"), "false");
 
-      $cancelButton = jQueryFrame($cancelButton.selector);
+      $cancelButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:cancel1");
       $cancelButton.click();
 
       step++;
       done();
     } else if (step == 2) {
-      $popup = jQueryFrame($popup.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
       assert.equal($popup.attr("value"), "true");
 
       done();
@@ -62,11 +62,11 @@ QUnit.test("Open 'Simple Popup', press 'Submit' while field is empty. Press 'Can
   assert.equal($popup.attr("value"), "true");
   $openButton.click();
 
-  jQuery("#page\\:testframe").load(function() {
+  jQuery("#page\\:testframe").on("load", function() {
     if (step == 1) {
-      $popup = jQueryFrame($popup.selector);
-      $inputField = jQueryFrame($inputField.selector);
-      $submitButton = jQueryFrame($submitButton.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $inputField = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:in1\\:\\:field");
+      $submitButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:submit1");
 
       assert.equal($popup.attr("value"), "false");
       $inputField.val("");
@@ -75,8 +75,8 @@ QUnit.test("Open 'Simple Popup', press 'Submit' while field is empty. Press 'Can
       step++;
       done();
     } else if (step == 2) {
-      $popup = jQueryFrame($popup.selector);
-      $cancelButton = jQueryFrame($cancelButton.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $cancelButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:cancel1");
 
       assert.equal($popup.attr("value"), "false");
       $cancelButton.click();
@@ -84,8 +84,8 @@ QUnit.test("Open 'Simple Popup', press 'Submit' while field is empty. Press 'Can
       step++;
       done();
     } else if (step == 3) {
-      $popup = jQueryFrame($popup.selector);
-      $output = jQueryFrame($output.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $output = jQueryFrame("#page\\:mainForm\\:form1\\:output span");
 
       assert.equal($popup.attr("value"), "true");
       assert.equal($output.text(), outputValue);
@@ -110,11 +110,11 @@ QUnit.test("Open 'Simple Popup', press 'Submit' while field has content. Press '
   assert.equal($popup.attr("value"), "true");
   $openButton.click();
 
-  jQuery("#page\\:testframe").load(function() {
+  jQuery("#page\\:testframe").on("load", function() {
     if (step == 1) {
-      $popup = jQueryFrame($popup.selector);
-      $inputField = jQueryFrame($inputField.selector);
-      $submitButton = jQueryFrame($submitButton.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $inputField = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:in1\\:\\:field");
+      $submitButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:submit1");
 
       assert.equal($popup.attr("value"), "false");
       $inputField.val("Hello Popup!");
@@ -123,8 +123,8 @@ QUnit.test("Open 'Simple Popup', press 'Submit' while field has content. Press '
       step++;
       done();
     } else if (step == 2) {
-      $popup = jQueryFrame($popup.selector);
-      $cancelButton = jQueryFrame($cancelButton.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $cancelButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:cancel1");
 
       assert.equal($popup.attr("value"), "false");
       $cancelButton.click();
@@ -132,8 +132,8 @@ QUnit.test("Open 'Simple Popup', press 'Submit' while field has content. Press '
       step++;
       done();
     } else if (step == 3) {
-      $popup = jQueryFrame($popup.selector);
-      $output = jQueryFrame($output.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $output = jQueryFrame("#page\\:mainForm\\:form1\\:output span");
 
       assert.equal($popup.attr("value"), "true");
       assert.equal($output.text(), "Hello Popup!");
@@ -159,11 +159,11 @@ QUnit.test("Open 'Simple Popup', press 'Submit & Close' while field is empty. Pr
   assert.equal($popup.attr("value"), "true");
   $openButton.click();
 
-  jQuery("#page\\:testframe").load(function() {
+  jQuery("#page\\:testframe").on("load", function() {
     if (step == 1) {
-      $popup = jQueryFrame($popup.selector);
-      $inputField = jQueryFrame($inputField.selector);
-      $submitCloseButton = jQueryFrame($submitCloseButton.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $inputField = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:in1\\:\\:field");
+      $submitCloseButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:submitClose1");
 
       assert.equal($popup.attr("value"), "false");
       $inputField.val("");
@@ -172,8 +172,8 @@ QUnit.test("Open 'Simple Popup', press 'Submit & Close' while field is empty. Pr
       step++;
       done();
     } else if (step == 2) {
-      $popup = jQueryFrame($popup.selector);
-      $cancelButton = jQueryFrame($cancelButton.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $cancelButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:cancel1");
 
       assert.equal($popup.attr("value"), "false");
       $cancelButton.click();
@@ -181,8 +181,8 @@ QUnit.test("Open 'Simple Popup', press 'Submit & Close' while field is empty. Pr
       step++;
       done();
     } else if (step == 3) {
-      $popup = jQueryFrame($popup.selector);
-      $output = jQueryFrame($output.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $output = jQueryFrame("#page\\:mainForm\\:form1\\:output span");
 
       assert.equal($popup.attr("value"), "true");
       assert.equal($output.text(), outputValue);
@@ -207,11 +207,11 @@ QUnit.test("Open 'Simple Popup', press 'Submit & Close' while field has content.
   assert.equal($popup.attr("value"), "true");
   $openButton.click();
 
-  jQuery("#page\\:testframe").load(function() {
+  jQuery("#page\\:testframe").on("load", function() {
     if (step == 1) {
-      $popup = jQueryFrame($popup.selector);
-      $inputField = jQueryFrame($inputField.selector);
-      $submitCloseButton = jQueryFrame($submitCloseButton.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $inputField = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:in1\\:\\:field");
+      $submitCloseButton = jQueryFrame("#page\\:mainForm\\:form1\\:popup\\:submitClose1");
 
       assert.equal($popup.attr("value"), "false");
       $inputField.val("press submit and close test");
@@ -220,8 +220,8 @@ QUnit.test("Open 'Simple Popup', press 'Submit & Close' while field has content.
       step++;
       done();
     } else if (step == 2) {
-      $popup = jQueryFrame($popup.selector);
-      $output = jQueryFrame($output.selector);
+      $popup = jQueryFrame("#page\\:mainForm\\:form1\\:popup input");
+      $output = jQueryFrame("#page\\:mainForm\\:form1\\:output span");
 
       assert.equal($popup.attr("value"), "true");
       assert.equal($output.text(), "press submit and close test");
@@ -266,12 +266,12 @@ QUnit.test("Open 'Client Popup', press 'Submit' while field is empty. Press 'Can
   $submitButton.click();
 
   waitForAjax(function() {
-    $messages = jQueryFrame($messages.selector);
+    $messages = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup\\:messages");
     return $messages.length == 1;
   }, function() {
-    $output = jQueryFrame($output.selector);
-    $messages = jQueryFrame($messages.selector);
-    $cancelButton = jQueryFrame($cancelButton.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:form2\\:output span");
+    $messages = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup\\:messages");
+    $cancelButton = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup\\:cancel2");
 
     assert.equal($messages.length, 1);
     $cancelButton.click();
@@ -301,12 +301,12 @@ QUnit.test("Open 'Client Popup', press 'Submit' while field has content. Press '
   $submitButton.click();
 
   waitForAjax(function() {
-    $messages = jQueryFrame($messages.selector);
+    $messages = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup\\:messages");
     return $messages.length == 0;
   }, function() {
-    $output = jQueryFrame($output.selector);
-    $messages = jQueryFrame($messages.selector);
-    $cancelButton = jQueryFrame($cancelButton.selector);
+    $output = jQueryFrame("#page\\:mainForm\\:form2\\:out span");
+    $messages = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup\\:messages");
+    $cancelButton = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup\\:cancel2");
 
     assert.equal($messages.length, 0);
     $cancelButton.click();
@@ -334,9 +334,9 @@ QUnit.test("Open 'Client Popup', press 'Submit & Close' while field is empty.",
   $inputField.val("");
   $submitCloseButton.click();
 
-  jQuery("#page\\:testframe").load(function() {
-    $popup = jQueryFrame($popup.selector);
-    $output = jQueryFrame($output.selector);
+  jQuery("#page\\:testframe").on("load", function() {
+    $popup = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup input");
+    $output = jQueryFrame("#page\\:mainForm\\:form2\\:output span");
 
     assert.equal($popup.attr("value"), "true");
     assert.equal($output.text(), outputValue);
@@ -361,9 +361,9 @@ QUnit.test("Open 'Simple Popup', press 'Submit & Close' while field has content.
   $inputField.val("test client popup - submit and close button");
   $submitCloseButton.click();
 
-  jQuery("#page\\:testframe").load(function() {
-    $popup = jQueryFrame($popup.selector);
-    $output = jQueryFrame($output.selector);
+  jQuery("#page\\:testframe").on("load", function() {
+    $popup = jQueryFrame("#page\\:mainForm\\:form2\\:clientPopup input");
+    $output = jQueryFrame("#page\\:mainForm\\:form2\\:out span");
 
     assert.equal($popup.attr("value"), "true");
     assert.equal($output.text(), "test client popup - submit and close button");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/10-sort/sheet-sorting.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/10-sort/sheet-sorting.test.js
index ad0744c..9348a35 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/10-sort/sheet-sorting.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/10-sort/sheet-sorting.test.js
@@ -15,38 +15,56 @@
  * limitations under the License.
  */
 
+Selectors = {};
+
+Selectors.s1colName = "#page\\:mainForm\\:s1\\:columnName_sorter";
+Selectors.s1colPeriod = "#page\\:mainForm\\:s1\\:columnPeriod_sorter";
+Selectors.s1colYear = "#page\\:mainForm\\:s1\\:columnDiscoverYear_sorter";
+Selectors.s1rows = "#page\\:mainForm\\:s1 .tobago-sheet-bodyTable tbody .tobago-sheet-row";
+Selectors.s1leftPaging = "#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-left input";
+Selectors.s1rightPaging = "#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-right .page-link";
+Selectors.s1centerPaging = "#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-center li .page-link";
+
+Selectors.s2colName = "#page\\:mainForm\\:s2\\:customColumnName_sorter";
+Selectors.s2colPeriod = "#page\\:mainForm\\:s2\\:customColumnPeriod_sorter";
+Selectors.s2colYear = "#page\\:mainForm\\:s2\\:customColumnYear_sorter";
+Selectors.s2rows = "#page\\:mainForm\\:s2 .tobago-sheet-bodyTable tbody .tobago-sheet-row";
+Selectors.s2leftPaging = "#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-left input";
+Selectors.s2rightPaging = "#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-right .page-link";
+Selectors.s2centerPaging = "#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-center li .page-link";
+
 QUnit.test("Basics: Name", function(assert) {
   assert.expect(37);
   var done = assert.async(4);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s1\\:columnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-left input");
+  var $colName = jQueryFrame(Selectors.s1colName);
+  var $rows = jQueryFrame(Selectors.s1rows);
+  var $leftPaging = jQueryFrame(Selectors.s1leftPaging);
 
   if ($colName.find(".fa-angle-up").length != 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     return $colName.find(".fa-angle-up").length == 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s1leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
           "Enceladus", "1.37", "1789",
           "Epimetheus", "0.69", "1980");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
@@ -57,14 +75,14 @@ QUnit.test("Basics: Name", function(assert) {
       $colName.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Proteus", "1.12", "1989",
             "Prospero", "-1962.95", "1999",
             "Prometheus", "0.61", "1980",
             "Praxidike", "625.3", "2000");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Proteus", "1.12", "1989",
             "Prospero", "-1962.95", "1999",
@@ -75,14 +93,14 @@ QUnit.test("Basics: Name", function(assert) {
         $colName.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Earth", "365.26", "",
               "Elara", "259.65", "1905",
               "Enceladus", "1.37", "1789",
               "Epimetheus", "0.69", "1980");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Earth", "365.26", "",
               "Elara", "259.65", "1905",
@@ -99,34 +117,34 @@ QUnit.test("Basics: Period", function(assert) {
   assert.expect(37);
   var done = assert.async(4);
 
-  var $colPeriod = jQueryFrame("#page\\:mainForm\\:s1\\:columnPeriod_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-left input");
+  var $colPeriod = jQueryFrame(Selectors.s1colPeriod);
+  var $rows = jQueryFrame(Selectors.s1rows);
+  var $leftPaging = jQueryFrame(Selectors.s1leftPaging);
 
   if ($colPeriod.find(".fa-angle-up").length != 1) {
     $colPeriod.click();
   }
 
   waitForAjax(function() {
-    $colPeriod = jQueryFrame($colPeriod.selector);
+    $colPeriod = jQueryFrame(Selectors.s1colPeriod);
     return $colPeriod.find(".fa-angle-up").length == 1;
   }, function() {
-    $colPeriod = jQueryFrame($colPeriod.selector);
+    $colPeriod = jQueryFrame(Selectors.s1colPeriod);
     assert.equal($colPeriod.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s1leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Galatea", "0.43", "1989",
           "Cressida", "0.46", "1986",
           "Desdemona", "0.47", "1986",
           "Juliet", "0.49", "1986");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Galatea", "0.43", "1989",
           "Cressida", "0.46", "1986",
@@ -137,14 +155,14 @@ QUnit.test("Basics: Period", function(assert) {
       $colPeriod.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Leda", "238.72", "1974",
             "Venus", "224.7", "",
             "Themisto", "130.02", "2000",
             "Mercury", "87.97", "");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Leda", "238.72", "1974",
             "Venus", "224.7", "",
@@ -155,14 +173,14 @@ QUnit.test("Basics: Period", function(assert) {
         $colPeriod.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Galatea", "0.43", "1989",
               "Cressida", "0.46", "1986",
               "Desdemona", "0.47", "1986",
               "Juliet", "0.49", "1986");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Galatea", "0.43", "1989",
               "Cressida", "0.46", "1986",
@@ -179,33 +197,33 @@ QUnit.test("Basics: Year", function(assert) {
   assert.expect(13);
   var done = assert.async(4);
 
-  var $colYear = jQueryFrame("#page\\:mainForm\\:s1\\:columnDiscoverYear_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-left input");
+  var $colYear = jQueryFrame(Selectors.s1colYear);
+  var $rows = jQueryFrame(Selectors.s1rows);
+  var $leftPaging = jQueryFrame(Selectors.s1leftPaging);
 
   if ($colYear.find(".fa-angle-up").length != 1) {
     $colYear.click();
   }
 
   waitForAjax(function() {
-    $colYear = jQueryFrame($colYear.selector);
+    $colYear = jQueryFrame(Selectors.s1colYear);
     return $colYear.find(".fa-angle-up").length == 1;
   }, function() {
-    $colYear = jQueryFrame($colYear.selector);
+    $colYear = jQueryFrame(Selectors.s1colYear);
     assert.equal($colYear.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s1leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       return $rows.eq(0).find(".tobago-sheet-cell span").eq(2).text() == "1789"
           && $rows.eq(1).find(".tobago-sheet-cell span").eq(2).text() == "1846"
           && $rows.eq(2).find(".tobago-sheet-cell span").eq(2).text() == "1846"
           && $rows.eq(3).find(".tobago-sheet-cell span").eq(2).text() == "1848";
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       assert.equal($rows.eq(0).find(".tobago-sheet-cell span").eq(2).text(), "1789", "row0col2");
       assert.equal($rows.eq(1).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row1col2");
       assert.equal($rows.eq(2).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row2col2");
@@ -215,13 +233,13 @@ QUnit.test("Basics: Year", function(assert) {
       $colYear.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         return $rows.eq(0).find(".tobago-sheet-cell span").eq(2).text() == "1989"
             && $rows.eq(1).find(".tobago-sheet-cell span").eq(2).text() == "1989"
             && $rows.eq(2).find(".tobago-sheet-cell span").eq(2).text() == "1989"
             && $rows.eq(3).find(".tobago-sheet-cell span").eq(2).text() == "1986";
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         assert.equal($rows.eq(0).find(".tobago-sheet-cell span").eq(2).text(), "1989", "row0col2");
         assert.equal($rows.eq(1).find(".tobago-sheet-cell span").eq(2).text(), "1989", "row1col2");
         assert.equal($rows.eq(2).find(".tobago-sheet-cell span").eq(2).text(), "1989", "row2col2");
@@ -231,13 +249,13 @@ QUnit.test("Basics: Year", function(assert) {
         $colYear.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           return $rows.eq(0).find(".tobago-sheet-cell span").eq(2).text() == "1789"
               && $rows.eq(1).find(".tobago-sheet-cell span").eq(2).text() == "1846"
               && $rows.eq(2).find(".tobago-sheet-cell span").eq(2).text() == "1846"
               && $rows.eq(3).find(".tobago-sheet-cell span").eq(2).text() == "1848";
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           assert.equal($rows.eq(0).find(".tobago-sheet-cell span").eq(2).text(), "1789", "row0col2");
           assert.equal($rows.eq(1).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row1col2");
           assert.equal($rows.eq(2).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row2col2");
@@ -257,34 +275,34 @@ QUnit.test("Basics: left paging", function(assert) {
   assert.expect(25);
   var done = assert.async(3);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s1\\:columnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-left input");
+  var $colName = jQueryFrame(Selectors.s1colName);
+  var $rows = jQueryFrame(Selectors.s1rows);
+  var $leftPaging = jQueryFrame(Selectors.s1leftPaging);
 
   if ($colName.find(".fa-angle-up").length != 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     return $colName.find(".fa-angle-up").length == 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s1leftPaging);
     $leftPaging.val("8").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Bianca", "0.43", "1986",
           "Caliban", "-579.39", "1997",
           "Callirrhoe", "758.8", "2000",
           "Callisto", "16.69", "1610");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Bianca", "0.43", "1986",
           "Caliban", "-579.39", "1997",
@@ -292,18 +310,18 @@ QUnit.test("Basics: left paging", function(assert) {
           "Callisto", "16.69", "1610");
       done();
 
-      $leftPaging = jQueryFrame($leftPaging.selector);
+      $leftPaging = jQueryFrame(Selectors.s1leftPaging);
       $leftPaging.val("9").trigger("blur");
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Caliban", "-579.39", "1997",
             "Callirrhoe", "758.8", "2000",
             "Callisto", "16.69", "1610",
             "Calypso", "1.89", "1980");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Caliban", "-579.39", "1997",
             "Callirrhoe", "758.8", "2000",
@@ -324,35 +342,35 @@ QUnit.test("Basics: center paging", function(assert) {
   assert.expect(49);
   var done = assert.async(5);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s1\\:columnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-left input");
-  var $centerPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-center li .page-link");
+  var $colName = jQueryFrame(Selectors.s1colName);
+  var $rows = jQueryFrame(Selectors.s1rows);
+  var $leftPaging = jQueryFrame(Selectors.s1leftPaging);
+  var $centerPaging = jQueryFrame(Selectors.s1centerPaging);
 
   if ($colName.find(".fa-angle-up").length != 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     return $colName.find(".fa-angle-up").length == 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s1leftPaging);
     $leftPaging.val("1").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       return ajaxWaitingBodyTableCheck($rows,
           "1986U10", "0.64", "1999",
           "Adrastea", "0.3", "1979",
           "Amalthea", "0.5", "1892",
           "Ananke", "-629.77", "1951");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "1986U10", "0.64", "1999",
           "Adrastea", "0.3", "1979",
@@ -360,18 +378,18 @@ QUnit.test("Basics: center paging", function(assert) {
           "Ananke", "-629.77", "1951");
       done();
 
-      $centerPaging = jQueryFrame($centerPaging.selector);
+      $centerPaging = jQueryFrame(Selectors.s1centerPaging);
       $centerPaging.eq(6).click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Epimetheus", "0.69", "1980",
             "Erinome", "728.3", "2000",
             "Europa", "3.55", "1610",
             "Galatea", "0.43", "1989");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Epimetheus", "0.69", "1980",
             "Erinome", "728.3", "2000",
@@ -379,18 +397,18 @@ QUnit.test("Basics: center paging", function(assert) {
             "Galatea", "0.43", "1989");
         done();
 
-        $centerPaging = jQueryFrame($centerPaging.selector);
+        $centerPaging = jQueryFrame(Selectors.s1centerPaging);
         $centerPaging.eq(10).click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Phoebe", "-550.48", "1898",
               "Pluto", "90800.0", "1930",
               "Portia", "0.51", "1986",
               "Praxidike", "625.3", "2000");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Phoebe", "-550.48", "1898",
               "Pluto", "90800.0", "1930",
@@ -398,18 +416,18 @@ QUnit.test("Basics: center paging", function(assert) {
               "Praxidike", "625.3", "2000");
           done();
 
-          $centerPaging = jQueryFrame($centerPaging.selector);
+          $centerPaging = jQueryFrame(Selectors.s1centerPaging);
           $centerPaging.eq(3).click();
 
           waitForAjax(function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s1rows);
             return ajaxWaitingBodyTableCheck($rows,
                 "Neptune", "60190.0", "1846",
                 "Nereid", "360.13", "1949",
                 "Oberon", "13.46", "1787",
                 "Ophelia", "0.38", "1986");
           }, function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s1rows);
             ajaxExecuteBodyTableCheck(assert, $rows,
                 "Neptune", "60190.0", "1846",
                 "Nereid", "360.13", "1949",
@@ -434,35 +452,35 @@ QUnit.test("Basics: right paging", function(assert) {
   assert.expect(61);
   var done = assert.async(6);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s1\\:columnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-left input");
-  var $rightPaging = jQueryFrame("#page\\:mainForm\\:s1 .tobago-sheet-paging-markup-right .page-link");
+  var $colName = jQueryFrame(Selectors.s1colName);
+  var $rows = jQueryFrame(Selectors.s1rows);
+  var $leftPaging = jQueryFrame(Selectors.s1leftPaging);
+  var $rightPaging = jQueryFrame(Selectors.s1rightPaging);
 
   if ($colName.find(".fa-angle-up").length != 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     return $colName.find(".fa-angle-up").length == 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s1colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s1leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
           "Enceladus", "1.37", "1789",
           "Epimetheus", "0.69", "1980");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s1rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
@@ -470,18 +488,18 @@ QUnit.test("Basics: right paging", function(assert) {
           "Epimetheus", "0.69", "1980");
       done();
 
-      var $rightPagingFirstPage = jQueryFrame($rightPaging.selector).eq(0);
+      var $rightPagingFirstPage = jQueryFrame(Selectors.s1rightPaging).eq(0);
       $rightPagingFirstPage.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         return ajaxWaitingBodyTableCheck($rows,
             "1986U10", "0.64", "1999",
             "Adrastea", "0.3", "1979",
             "Amalthea", "0.5", "1892",
             "Ananke", "-629.77", "1951");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s1rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "1986U10", "0.64", "1999",
             "Adrastea", "0.3", "1979",
@@ -489,18 +507,18 @@ QUnit.test("Basics: right paging", function(assert) {
             "Ananke", "-629.77", "1951");
         done();
 
-        var $rightPagingRight = jQueryFrame($rightPaging.selector).eq(3);
+        var $rightPagingRight = jQueryFrame(Selectors.s1rightPaging).eq(3);
         $rightPagingRight.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Ariel", "2.52", "1851",
               "Atlas", "0.6", "1980",
               "Belinda", "0.62", "1986",
               "Bianca", "0.43", "1986");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s1rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Ariel", "2.52", "1851",
               "Atlas", "0.6", "1980",
@@ -508,18 +526,18 @@ QUnit.test("Basics: right paging", function(assert) {
               "Bianca", "0.43", "1986");
           done();
 
-          var $rightPagingLastPage = jQueryFrame($rightPaging.selector).eq(4);
+          var $rightPagingLastPage = jQueryFrame(Selectors.s1rightPaging).eq(4);
           $rightPagingLastPage.click();
 
           waitForAjax(function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s1rows);
             return ajaxWaitingBodyTableCheck($rows,
                 "Triton", "-5.88", "1846",
                 "Umbriel", "4.14", "1851",
                 "Uranus", "30685.0", "1781",
                 "Venus", "224.7", "");
           }, function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s1rows);
             ajaxExecuteBodyTableCheck(assert, $rows,
                 "Triton", "-5.88", "1846",
                 "Umbriel", "4.14", "1851",
@@ -527,18 +545,18 @@ QUnit.test("Basics: right paging", function(assert) {
                 "Venus", "224.7", "");
             done();
 
-            var $rightPagingLeft = jQueryFrame($rightPaging.selector).eq(1);
+            var $rightPagingLeft = jQueryFrame(Selectors.s1rightPaging).eq(1);
             $rightPagingLeft.click();
 
             waitForAjax(function() {
-              $rows = jQueryFrame($rows.selector);
+              $rows = jQueryFrame(Selectors.s1rows);
               return ajaxWaitingBodyTableCheck($rows,
                   "Thebe", "0.67", "1979",
                   "Themisto", "130.02", "2000",
                   "Titan", "15.95", "1655",
                   "Titania", "8.71", "1787");
             }, function() {
-              $rows = jQueryFrame($rows.selector);
+              $rows = jQueryFrame(Selectors.s1rows);
               ajaxExecuteBodyTableCheck(assert, $rows,
                   "Thebe", "0.67", "1979",
                   "Themisto", "130.02", "2000",
@@ -546,18 +564,18 @@ QUnit.test("Basics: right paging", function(assert) {
                   "Titania", "8.71", "1787");
               done();
 
-              var $rightPagingJumpToPage = jQueryFrame($rightPaging.selector).find("input");
+              var $rightPagingJumpToPage = jQueryFrame(Selectors.s1rightPaging).find("input");
               $rightPagingJumpToPage.val("14").trigger("blur");
 
               waitForAjax(function() {
-                $rows = jQueryFrame($rows.selector);
+                $rows = jQueryFrame(Selectors.s1rows);
                 return ajaxWaitingBodyTableCheck($rows,
                     "Neptune", "60190.0", "1846",
                     "Nereid", "360.13", "1949",
                     "Oberon", "13.46", "1787",
                     "Ophelia", "0.38", "1986");
               }, function() {
-                $rows = jQueryFrame($rows.selector);
+                $rows = jQueryFrame(Selectors.s1rows);
                 ajaxExecuteBodyTableCheck(assert, $rows,
                     "Neptune", "60190.0", "1846",
                     "Nereid", "360.13", "1949",
@@ -577,34 +595,34 @@ QUnit.test("Custom Sorting: Name", function(assert) {
   assert.expect(37);
   var done = assert.async(4);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s2\\:customColumnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-left input");
+  var $colName = jQueryFrame(Selectors.s2colName);
+  var $rows = jQueryFrame(Selectors.s2rows);
+  var $leftPaging = jQueryFrame(Selectors.s2leftPaging);
 
-  if ($colName.find(".fa-angle-up").length != 1) {
+  if ($colName.find(".fa-angle-up").length !== 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
-    return $colName.find(".fa-angle-up").length == 1;
+    $colName = jQueryFrame(Selectors.s2colName);
+    return $colName.find(".fa-angle-up").length === 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s2colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s2leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
           "Enceladus", "1.37", "1789",
           "Epimetheus", "0.69", "1980");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
@@ -615,14 +633,14 @@ QUnit.test("Custom Sorting: Name", function(assert) {
       $colName.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Proteus", "1.12", "1989",
             "Prospero", "-1962.95", "1999",
             "Prometheus", "0.61", "1980",
             "Praxidike", "625.3", "2000");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Proteus", "1.12", "1989",
             "Prospero", "-1962.95", "1999",
@@ -633,14 +651,14 @@ QUnit.test("Custom Sorting: Name", function(assert) {
         $colName.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Earth", "365.26", "",
               "Elara", "259.65", "1905",
               "Enceladus", "1.37", "1789",
               "Epimetheus", "0.69", "1980");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Earth", "365.26", "",
               "Elara", "259.65", "1905",
@@ -657,34 +675,34 @@ QUnit.test("Custom Sorting: Period", function(assert) {
   assert.expect(37);
   var done = assert.async(4);
 
-  var $colPeriod = jQueryFrame("#page\\:mainForm\\:s2\\:customColumnPeriod_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-left input");
+  var $colPeriod = jQueryFrame(Selectors.s2colPeriod);
+  var $rows = jQueryFrame(Selectors.s2rows);
+  var $leftPaging = jQueryFrame(Selectors.s2leftPaging);
 
   if ($colPeriod.find(".fa-angle-up").length != 1) {
     $colPeriod.click();
   }
 
   waitForAjax(function() {
-    $colPeriod = jQueryFrame($colPeriod.selector);
+    $colPeriod = jQueryFrame(Selectors.s2colPeriod);
     return $colPeriod.find(".fa-angle-up").length == 1;
   }, function() {
-    $colPeriod = jQueryFrame($colPeriod.selector);
+    $colPeriod = jQueryFrame(Selectors.s2colPeriod);
     assert.equal($colPeriod.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s2leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Belinda", "0.62", "1986",
           "Pandora", "0.63", "1980",
           "1986U10", "0.64", "1999",
           "Thebe", "0.67", "1979");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Belinda", "0.62", "1986",
           "Pandora", "0.63", "1980",
@@ -695,14 +713,14 @@ QUnit.test("Custom Sorting: Period", function(assert) {
       $colPeriod.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Ananke", "-629.77", "1951",
             "Praxidike", "625.3", "2000",
             "Harpalyke", "623.3", "2000",
             "Caliban", "-579.39", "1997");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Ananke", "-629.77", "1951",
             "Praxidike", "625.3", "2000",
@@ -713,14 +731,14 @@ QUnit.test("Custom Sorting: Period", function(assert) {
         $colPeriod.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Belinda", "0.62", "1986",
               "Pandora", "0.63", "1980",
               "1986U10", "0.64", "1999",
               "Thebe", "0.67", "1979");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Belinda", "0.62", "1986",
               "Pandora", "0.63", "1980",
@@ -737,33 +755,33 @@ QUnit.test("Custom Sorting: Year", function(assert) {
   assert.expect(13);
   var done = assert.async(4);
 
-  var $colYear = jQueryFrame("#page\\:mainForm\\:s2\\:customColumnYear_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-left input");
+  var $colYear = jQueryFrame(Selectors.s2colYear);
+  var $rows = jQueryFrame(Selectors.s2rows);
+  var $leftPaging = jQueryFrame(Selectors.s2leftPaging);
 
   if ($colYear.find(".fa-angle-up").length != 1) {
     $colYear.click();
   }
 
   waitForAjax(function() {
-    $colYear = jQueryFrame($colYear.selector);
+    $colYear = jQueryFrame(Selectors.s2colYear);
     return $colYear.find(".fa-angle-up").length == 1;
   }, function() {
-    $colYear = jQueryFrame($colYear.selector);
+    $colYear = jQueryFrame(Selectors.s2colYear);
     assert.equal($colYear.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s2leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       return $rows.eq(0).find(".tobago-sheet-cell span").eq(2).text() == "1789"
           && $rows.eq(1).find(".tobago-sheet-cell span").eq(2).text() == "1846"
           && $rows.eq(2).find(".tobago-sheet-cell span").eq(2).text() == "1846"
           && $rows.eq(3).find(".tobago-sheet-cell span").eq(2).text() == "1848";
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       assert.equal($rows.eq(0).find(".tobago-sheet-cell span").eq(2).text(), "1789", "row0col2");
       assert.equal($rows.eq(1).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row1col2");
       assert.equal($rows.eq(2).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row2col2");
@@ -773,13 +791,13 @@ QUnit.test("Custom Sorting: Year", function(assert) {
       $colYear.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         return $rows.eq(0).find(".tobago-sheet-cell span").eq(2).text() == "1989"
             && $rows.eq(1).find(".tobago-sheet-cell span").eq(2).text() == "1989"
             && $rows.eq(2).find(".tobago-sheet-cell span").eq(2).text() == "1989"
             && $rows.eq(3).find(".tobago-sheet-cell span").eq(2).text() == "1986";
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         assert.equal($rows.eq(0).find(".tobago-sheet-cell span").eq(2).text(), "1989", "row0col2");
         assert.equal($rows.eq(1).find(".tobago-sheet-cell span").eq(2).text(), "1989", "row1col2");
         assert.equal($rows.eq(2).find(".tobago-sheet-cell span").eq(2).text(), "1989", "row2col2");
@@ -789,13 +807,13 @@ QUnit.test("Custom Sorting: Year", function(assert) {
         $colYear.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           return $rows.eq(0).find(".tobago-sheet-cell span").eq(2).text() == "1789"
               && $rows.eq(1).find(".tobago-sheet-cell span").eq(2).text() == "1846"
               && $rows.eq(2).find(".tobago-sheet-cell span").eq(2).text() == "1846"
               && $rows.eq(3).find(".tobago-sheet-cell span").eq(2).text() == "1848";
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           assert.equal($rows.eq(0).find(".tobago-sheet-cell span").eq(2).text(), "1789", "row0col2");
           assert.equal($rows.eq(1).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row1col2");
           assert.equal($rows.eq(2).find(".tobago-sheet-cell span").eq(2).text(), "1846", "row2col2");
@@ -815,34 +833,34 @@ QUnit.test("Custom Sorting: left paging", function(assert) {
   assert.expect(25);
   var done = assert.async(3);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s2\\:customColumnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-left input");
+  var $colName = jQueryFrame(Selectors.s2colName);
+  var $rows = jQueryFrame(Selectors.s2rows);
+  var $leftPaging = jQueryFrame(Selectors.s2leftPaging);
 
   if ($colName.find(".fa-angle-up").length != 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s2colName);
     return $colName.find(".fa-angle-up").length == 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s2colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s2leftPaging);
     $leftPaging.val("8").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Bianca", "0.43", "1986",
           "Caliban", "-579.39", "1997",
           "Callirrhoe", "758.8", "2000",
           "Callisto", "16.69", "1610");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Bianca", "0.43", "1986",
           "Caliban", "-579.39", "1997",
@@ -850,18 +868,18 @@ QUnit.test("Custom Sorting: left paging", function(assert) {
           "Callisto", "16.69", "1610");
       done();
 
-      $leftPaging = jQueryFrame($leftPaging.selector);
+      $leftPaging = jQueryFrame(Selectors.s2leftPaging);
       $leftPaging.val("9").trigger("blur");
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Caliban", "-579.39", "1997",
             "Callirrhoe", "758.8", "2000",
             "Callisto", "16.69", "1610",
             "Calypso", "1.89", "1980");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Caliban", "-579.39", "1997",
             "Callirrhoe", "758.8", "2000",
@@ -882,35 +900,35 @@ QUnit.test("Custom Sorting: center paging", function(assert) {
   assert.expect(49);
   var done = assert.async(5);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s2\\:customColumnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-left input");
-  var $centerPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-center li .page-link");
+  var $colName = jQueryFrame(Selectors.s2colName);
+  var $rows = jQueryFrame(Selectors.s2rows);
+  var $leftPaging = jQueryFrame(Selectors.s2leftPaging);
+  var $centerPaging = jQueryFrame(Selectors.s2centerPaging);
 
   if ($colName.find(".fa-angle-up").length != 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s2colName);
     return $colName.find(".fa-angle-up").length == 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s2colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s2leftPaging);
     $leftPaging.val("1").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       return ajaxWaitingBodyTableCheck($rows,
           "1986U10", "0.64", "1999",
           "Adrastea", "0.3", "1979",
           "Amalthea", "0.5", "1892",
           "Ananke", "-629.77", "1951");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "1986U10", "0.64", "1999",
           "Adrastea", "0.3", "1979",
@@ -918,18 +936,18 @@ QUnit.test("Custom Sorting: center paging", function(assert) {
           "Ananke", "-629.77", "1951");
       done();
 
-      $centerPaging = jQueryFrame($centerPaging.selector);
+      $centerPaging = jQueryFrame(Selectors.s2centerPaging);
       $centerPaging.eq(6).click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         return ajaxWaitingBodyTableCheck($rows,
             "Epimetheus", "0.69", "1980",
             "Erinome", "728.3", "2000",
             "Europa", "3.55", "1610",
             "Galatea", "0.43", "1989");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "Epimetheus", "0.69", "1980",
             "Erinome", "728.3", "2000",
@@ -937,18 +955,18 @@ QUnit.test("Custom Sorting: center paging", function(assert) {
             "Galatea", "0.43", "1989");
         done();
 
-        $centerPaging = jQueryFrame($centerPaging.selector);
+        $centerPaging = jQueryFrame(Selectors.s2centerPaging);
         $centerPaging.eq(10).click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Phoebe", "-550.48", "1898",
               "Pluto", "90800.0", "1930",
               "Portia", "0.51", "1986",
               "Praxidike", "625.3", "2000");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Phoebe", "-550.48", "1898",
               "Pluto", "90800.0", "1930",
@@ -956,18 +974,18 @@ QUnit.test("Custom Sorting: center paging", function(assert) {
               "Praxidike", "625.3", "2000");
           done();
 
-          $centerPaging = jQueryFrame($centerPaging.selector);
+          $centerPaging = jQueryFrame(Selectors.s2centerPaging);
           $centerPaging.eq(3).click();
 
           waitForAjax(function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s2rows);
             return ajaxWaitingBodyTableCheck($rows,
                 "Neptune", "60190.0", "1846",
                 "Nereid", "360.13", "1949",
                 "Oberon", "13.46", "1787",
                 "Ophelia", "0.38", "1986");
           }, function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s2rows);
             ajaxExecuteBodyTableCheck(assert, $rows,
                 "Neptune", "60190.0", "1846",
                 "Nereid", "360.13", "1949",
@@ -992,35 +1010,35 @@ QUnit.test("Custom Sorting: right paging", function(assert) {
   assert.expect(61);
   var done = assert.async(6);
 
-  var $colName = jQueryFrame("#page\\:mainForm\\:s2\\:customColumnName_sorter");
-  var $rows = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-bodyTable tbody .tobago-sheet-row");
-  var $leftPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-left input");
-  var $rightPaging = jQueryFrame("#page\\:mainForm\\:s2 .tobago-sheet-paging-markup-right .page-link");
+  var $colName = jQueryFrame(Selectors.s2colName);
+  var $rows = jQueryFrame(Selectors.s2rows);
+  var $leftPaging = jQueryFrame(Selectors.s2leftPaging);
+  var $rightPaging = jQueryFrame(Selectors.s2rightPaging);
 
   if ($colName.find(".fa-angle-up").length != 1) {
     $colName.click();
   }
 
   waitForAjax(function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s2colName);
     return $colName.find(".fa-angle-up").length == 1;
   }, function() {
-    $colName = jQueryFrame($colName.selector);
+    $colName = jQueryFrame(Selectors.s2colName);
     assert.equal($colName.find(".fa-angle-up").length, 1);
     done();
 
-    $leftPaging = jQueryFrame($leftPaging.selector);
+    $leftPaging = jQueryFrame(Selectors.s2leftPaging);
     $leftPaging.val("22").trigger("blur");
 
     waitForAjax(function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       return ajaxWaitingBodyTableCheck($rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
           "Enceladus", "1.37", "1789",
           "Epimetheus", "0.69", "1980");
     }, function() {
-      $rows = jQueryFrame($rows.selector);
+      $rows = jQueryFrame(Selectors.s2rows);
       ajaxExecuteBodyTableCheck(assert, $rows,
           "Earth", "365.26", "",
           "Elara", "259.65", "1905",
@@ -1028,18 +1046,18 @@ QUnit.test("Custom Sorting: right paging", function(assert) {
           "Epimetheus", "0.69", "1980");
       done();
 
-      var $rightPagingFirstPage = jQueryFrame($rightPaging.selector).eq(0);
+      var $rightPagingFirstPage = jQueryFrame(Selectors.s2rightPaging).eq(0);
       $rightPagingFirstPage.click();
 
       waitForAjax(function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         return ajaxWaitingBodyTableCheck($rows,
             "1986U10", "0.64", "1999",
             "Adrastea", "0.3", "1979",
             "Amalthea", "0.5", "1892",
             "Ananke", "-629.77", "1951");
       }, function() {
-        $rows = jQueryFrame($rows.selector);
+        $rows = jQueryFrame(Selectors.s2rows);
         ajaxExecuteBodyTableCheck(assert, $rows,
             "1986U10", "0.64", "1999",
             "Adrastea", "0.3", "1979",
@@ -1047,18 +1065,18 @@ QUnit.test("Custom Sorting: right paging", function(assert) {
             "Ananke", "-629.77", "1951");
         done();
 
-        var $rightPagingRight = jQueryFrame($rightPaging.selector).eq(3);
+        var $rightPagingRight = jQueryFrame(Selectors.s2rightPaging).eq(3);
         $rightPagingRight.click();
 
         waitForAjax(function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           return ajaxWaitingBodyTableCheck($rows,
               "Ariel", "2.52", "1851",
               "Atlas", "0.6", "1980",
               "Belinda", "0.62", "1986",
               "Bianca", "0.43", "1986");
         }, function() {
-          $rows = jQueryFrame($rows.selector);
+          $rows = jQueryFrame(Selectors.s2rows);
           ajaxExecuteBodyTableCheck(assert, $rows,
               "Ariel", "2.52", "1851",
               "Atlas", "0.6", "1980",
@@ -1066,18 +1084,18 @@ QUnit.test("Custom Sorting: right paging", function(assert) {
               "Bianca", "0.43", "1986");
           done();
 
-          var $rightPagingLastPage = jQueryFrame($rightPaging.selector).eq(4);
+          var $rightPagingLastPage = jQueryFrame(Selectors.s2rightPaging).eq(4);
           $rightPagingLastPage.click();
 
           waitForAjax(function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s2rows);
             return ajaxWaitingBodyTableCheck($rows,
                 "Triton", "-5.88", "1846",
                 "Umbriel", "4.14", "1851",
                 "Uranus", "30685.0", "1781",
                 "Venus", "224.7", "");
           }, function() {
-            $rows = jQueryFrame($rows.selector);
+            $rows = jQueryFrame(Selectors.s2rows);
             ajaxExecuteBodyTableCheck(assert, $rows,
                 "Triton", "-5.88", "1846",
                 "Umbriel", "4.14", "1851",
@@ -1085,18 +1103,18 @@ QUnit.test("Custom Sorting: right paging", function(assert) {
                 "Venus", "224.7", "");
             done();
 
-            var $rightPagingLeft = jQueryFrame($rightPaging.selector).eq(1);
+            var $rightPagingLeft = jQueryFrame(Selectors.s2rightPaging).eq(1);
             $rightPagingLeft.click();
 
             waitForAjax(function() {
-              $rows = jQueryFrame($rows.selector);
+              $rows = jQueryFrame(Selectors.s2rows);
               return ajaxWaitingBodyTableCheck($rows,
                   "Thebe", "0.67", "1979",
                   "Themisto", "130.02", "2000",
                   "Titan", "15.95", "1655",
                   "Titania", "8.71", "1787");
             }, function() {
-              $rows = jQueryFrame($rows.selector);
+              $rows = jQueryFrame(Selectors.s2rows);
               ajaxExecuteBodyTableCheck(assert, $rows,
                   "Thebe", "0.67", "1979",
                   "Themisto", "130.02", "2000",
@@ -1104,18 +1122,18 @@ QUnit.test("Custom Sorting: right paging", function(assert) {
                   "Titania", "8.71", "1787");
               done();
 
-              var $rightPagingJumpToPage = jQueryFrame($rightPaging.selector).find("input");
+              var $rightPagingJumpToPage = jQueryFrame(Selectors.s2rightPaging).find("input");
               $rightPagingJumpToPage.val("14").trigger("blur");
 
               waitForAjax(function() {
-                $rows = jQueryFrame($rows.selector);
+                $rows = jQueryFrame(Selectors.s2rows);
                 return ajaxWaitingBodyTableCheck($rows,
                     "Neptune", "60190.0", "1846",
                     "Nereid", "360.13", "1949",
                     "Oberon", "13.46", "1787",
                     "Ophelia", "0.38", "1986");
               }, function() {
-                $rows = jQueryFrame($rows.selector);
+                $rows = jQueryFrame(Selectors.s2rows);
                 ajaxExecuteBodyTableCheck(assert, $rows,
                     "Neptune", "60190.0", "1846",
                     "Nereid", "360.13", "1949",
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/30-event/sheet-event.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/30-event/sheet-event.test.js
index 874c9fd..ac5b431 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/30-event/sheet-event.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/080-sheet/30-event/sheet-event.test.js
@@ -15,27 +15,43 @@
  * limitations under the License.
  */
 
+Selectors = {};
+
+Selectors.oneClickAjax = "#page\\:mainForm\\:changeExample\\:\\:0";
+Selectors.oneClickFullRequest = "#page\\:mainForm\\:changeExample\\:\\:1";
+Selectors.doubleClickFullRequest = "#page\\:mainForm\\:changeExample\\:\\:2";
+Selectors.venus0 = "#page\\:mainForm\\:s1\\:2\\:sample0";
+Selectors.venus1 = "#page\\:mainForm\\:s1\\:2\\:sample1";
+Selectors.venus2 = "#page\\:mainForm\\:s1\\:2\\:sample2";
+Selectors.jupiter0 = "#page\\:mainForm\\:s1\\:5\\:sample0";
+Selectors.jupiter1 = "#page\\:mainForm\\:s1\\:5\\:sample1";
+Selectors.jupiter2 = "#page\\:mainForm\\:s1\\:5\\:sample2";
+Selectors.saturn0 = "#page\\:mainForm\\:s1\\:6\\:sample0";
+Selectors.saturn1 = "#page\\:mainForm\\:s1\\:6\\:sample1";
+Selectors.saturn2 = "#page\\:mainForm\\:s1\\:6\\:sample2";
+Selectors.namefield = "#page\\:mainForm\\:name\\:\\:field";
+
 QUnit.test("On click with ajax", function(assert) {
   assert.expect(6);
   var done = assert.async(4);
 
-  $oneClickAjax = jQueryFrame("#page\\:mainForm\\:changeExample\\:\\:0");
-  $venus = jQueryFrame("#page\\:mainForm\\:s1\\:2\\:sample0");
-  $jupiter = jQueryFrame("#page\\:mainForm\\:s1\\:5\\:sample0");
-  $saturn = jQueryFrame("#page\\:mainForm\\:s1\\:6\\:sample0");
-  $namefield = jQueryFrame("#page\\:mainForm\\:name\\:\\:field");
+  var $oneClickAjax = jQueryFrame(Selectors.oneClickAjax);
+  var $venus = jQueryFrame(Selectors.venus0);
+  var $jupiter = jQueryFrame(Selectors.jupiter0);
+  var $saturn = jQueryFrame(Selectors.saturn0);
+  var $namefield = jQueryFrame(Selectors.namefield);
 
   $oneClickAjax.click();
 
   waitForAjax(function() {
-    $venus = jQueryFrame($venus.selector);
-    $jupiter = jQueryFrame($jupiter.selector);
-    $saturn = jQueryFrame($saturn.selector);
-    return $venus.length == 1 && $jupiter.length == 1 && $saturn.length == 1;
+    $venus = jQueryFrame(Selectors.venus0);
+    $jupiter = jQueryFrame(Selectors.jupiter0);
+    $saturn = jQueryFrame(Selectors.saturn0);
+    return $venus.length === 1 && $jupiter.length === 1 && $saturn.length === 1;
   }, function() {
-    $venus = jQueryFrame($venus.selector);
-    $jupiter = jQueryFrame($jupiter.selector);
-    $saturn = jQueryFrame($saturn.selector);
+    $venus = jQueryFrame(Selectors.venus0);
+    $jupiter = jQueryFrame(Selectors.jupiter0);
+    $saturn = jQueryFrame(Selectors.saturn0);
     assert.equal($venus.length, 1);
     assert.equal($jupiter.length, 1);
     assert.equal($saturn.length, 1);
@@ -44,30 +60,30 @@ QUnit.test("On click with ajax", function(assert) {
     $venus.click();
 
     waitForAjax(function() {
-      $namefield = jQueryFrame($namefield.selector);
-      return $namefield.val() == "Venus";
+      $namefield = jQueryFrame(Selectors.namefield);
+      return $namefield.val() === "Venus";
     }, function() {
-      $namefield = jQueryFrame($namefield.selector);
+      $namefield = jQueryFrame(Selectors.namefield);
       assert.equal($namefield.val(), "Venus");
       done();
 
       $jupiter.click();
 
       waitForAjax(function() {
-        $namefield = jQueryFrame($namefield.selector);
-        return $namefield.val() == "Jupiter";
+        $namefield = jQueryFrame(Selectors.namefield);
+        return $namefield.val() === "Jupiter";
       }, function() {
-        $namefield = jQueryFrame($namefield.selector);
+        $namefield = jQueryFrame(Selectors.namefield);
         assert.equal($namefield.val(), "Jupiter");
         done();
 
         $saturn.click();
 
         waitForAjax(function() {
-          $namefield = jQueryFrame($namefield.selector);
-          return $namefield.val() == "Saturn";
+          $namefield = jQueryFrame(Selectors.namefield);
+          return $namefield.val() === "Saturn";
         }, function() {
-          $namefield = jQueryFrame($namefield.selector);
+          $namefield = jQueryFrame(Selectors.namefield);
           assert.equal($namefield.val(), "Saturn");
           done();
         });
@@ -81,24 +97,24 @@ QUnit.test("On click with full request", function(assert) {
   var done = assert.async(4);
   var step = 1;
 
-  $oneClickFullRequest = jQueryFrame("#page\\:mainForm\\:changeExample\\:\\:1");
-  $venus = jQueryFrame("#page\\:mainForm\\:s1\\:2\\:sample1");
-  $jupiter = jQueryFrame("#page\\:mainForm\\:s1\\:5\\:sample1");
-  $saturn = jQueryFrame("#page\\:mainForm\\:s1\\:6\\:sample1");
-  $namefield = jQueryFrame("#page\\:mainForm\\:name\\:\\:field");
+  var $oneClickFullRequest = jQueryFrame(Selectors.oneClickFullRequest);
+  var $venus = jQueryFrame(Selectors.venus1);
+  var $jupiter = jQueryFrame(Selectors.jupiter1);
+  var $saturn = jQueryFrame(Selectors.saturn1);
+  var $namefield = jQueryFrame(Selectors.namefield);
 
   $oneClickFullRequest.click();
 
   waitForAjax(function() {
-    $venus = jQueryFrame($venus.selector);
-    $jupiter = jQueryFrame($jupiter.selector);
-    $saturn = jQueryFrame($saturn.selector);
-    return $venus.length == 1 && $jupiter.length == 1 && $saturn.length == 1;
+    $venus = jQueryFrame(Selectors.venus1);
+    $jupiter = jQueryFrame(Selectors.jupiter1);
+    $saturn = jQueryFrame(Selectors.saturn1);
+    return $venus.length === 1 && $jupiter.length === 1 && $saturn.length === 1;
   }, function() {
-    if (step == 1) {
-      $venus = jQueryFrame($venus.selector);
-      $jupiter = jQueryFrame($jupiter.selector);
-      $saturn = jQueryFrame($saturn.selector);
+    if (step === 1) {
+      $venus = jQueryFrame(Selectors.venus1);
+      $jupiter = jQueryFrame(Selectors.jupiter1);
+      $saturn = jQueryFrame(Selectors.saturn1);
       assert.equal($venus.length, 1);
       assert.equal($jupiter.length, 1);
       assert.equal($saturn.length, 1);
@@ -110,21 +126,21 @@ QUnit.test("On click with full request", function(assert) {
     step++;
   });
 
-  jQuery("#page\\:testframe").load(function() {
-    if (step == 2) {
-      $namefield = jQueryFrame($namefield.selector);
+  jQuery("#page\\:testframe").on("load", function() {
+    if (step === 2) {
+      $namefield = jQueryFrame(Selectors.namefield);
       assert.equal($namefield.val(), "Venus");
 
-      $jupiter = jQueryFrame($jupiter.selector);
+      $jupiter = jQueryFrame(Selectors.jupiter1);
       $jupiter.click();
-    } else if (step == 3) {
-      $namefield = jQueryFrame($namefield.selector);
+    } else if (step === 3) {
+      $namefield = jQueryFrame(Selectors.namefield);
       assert.equal($namefield.val(), "Jupiter");
 
-      $saturn = jQueryFrame($saturn.selector);
+      $saturn = jQueryFrame(Selectors.saturn1);
       $saturn.click();
-    } else if (step == 4) {
-      $namefield = jQueryFrame($namefield.selector);
+    } else if (step === 4) {
+      $namefield = jQueryFrame(Selectors.namefield);
       assert.equal($namefield.val(), "Saturn");
     }
 
@@ -138,24 +154,24 @@ QUnit.test("On double click with full request", function(assert) {
   var done = assert.async(4);
   var step = 1;
 
-  $doubleClickFullRequest = jQueryFrame("#page\\:mainForm\\:changeExample\\:\\:2");
-  $venus = jQueryFrame("#page\\:mainForm\\:s1\\:2\\:sample2");
-  $jupiter = jQueryFrame("#page\\:mainForm\\:s1\\:5\\:sample2");
-  $saturn = jQueryFrame("#page\\:mainForm\\:s1\\:6\\:sample2");
-  $namefield = jQueryFrame("#page\\:mainForm\\:name\\:\\:field");
+  var $doubleClickFullRequest = jQueryFrame(Selectors.doubleClickFullRequest);
+  var $venus = jQueryFrame(Selectors.venus2);
+  var $jupiter = jQueryFrame(Selectors.jupiter2);
+  var $saturn = jQueryFrame(Selectors.saturn2);
+  var $namefield = jQueryFrame(Selectors.namefield);
 
   $doubleClickFullRequest.click();
 
   waitForAjax(function() {
-    $venus = jQueryFrame($venus.selector);
-    $jupiter = jQueryFrame($jupiter.selector);
-    $saturn = jQueryFrame($saturn.selector);
-    return $venus.length == 1 && $jupiter.length == 1 && $saturn.length == 1;
+    $venus = jQueryFrame(Selectors.venus2);
+    $jupiter = jQueryFrame(Selectors.jupiter2);
+    $saturn = jQueryFrame(Selectors.saturn2);
+    return $venus.length === 1 && $jupiter.length === 1 && $saturn.length === 1;
   }, function() {
-    if (step == 1) {
-      $venus = jQueryFrame($venus.selector);
-      $jupiter = jQueryFrame($jupiter.selector);
-      $saturn = jQueryFrame($saturn.selector);
+    if (step === 1) {
+      $venus = jQueryFrame(Selectors.venus2);
+      $jupiter = jQueryFrame(Selectors.jupiter2);
+      $saturn = jQueryFrame(Selectors.saturn2);
       assert.equal($venus.length, 1);
       assert.equal($jupiter.length, 1);
       assert.equal($saturn.length, 1);
@@ -167,21 +183,21 @@ QUnit.test("On double click with full request", function(assert) {
     step++;
   });
 
-  jQuery("#page\\:testframe").load(function() {
-    if (step == 2) {
-      $namefield = jQueryFrame($namefield.selector);
+  jQuery("#page\\:testframe").on("load", function() {
+    if (step === 2) {
+      $namefield = jQueryFrame(Selectors.namefield);
       assert.equal($namefield.val(), "Venus");
 
-      $jupiter = jQueryFrame($jupiter.selector);
+      $jupiter = jQueryFrame(Selectors.jupiter2);
       $jupiter.dblclick();
-    } else if (step == 3) {
-      $namefield = jQueryFrame($namefield.selector);
+    } else if (step === 3) {
+      $namefield = jQueryFrame(Selectors.namefield);
       assert.equal($namefield.val(), "Jupiter");
 
-      $saturn = jQueryFrame($saturn.selector);
+      $saturn = jQueryFrame(Selectors.saturn2);
       $saturn.dblclick();
-    } else if (step == 4) {
-      $namefield = jQueryFrame($namefield.selector);
+    } else if (step === 4) {
+      $namefield = jQueryFrame(Selectors.namefield);
       assert.equal($namefield.val(), "Saturn");
     }
 
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/090-tree/01-select/tree-select.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/090-tree/01-select/tree-select.test.js
index 579db02..7c7cc5f 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/090-tree/01-select/tree-select.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/20-component/090-tree/01-select/tree-select.test.js
@@ -18,20 +18,25 @@
 QUnit.test("single: select Music, select Mathematics", function(assert) {
   assert.expect(4);
   var done = assert.async(4);
-  var $music = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:3\\:select");
-  var $mathematics = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:9\\:select");
-  var $output = jQueryFrame("#page\\:mainForm\\:selectedNodesOutput span");
-  var $selectableNone = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:0");
-  var $selectableSingle = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:1");
+  var mu = "#page\\:mainForm\\:categoriesTree\\:3\\:select";
+  var $music = jQueryFrame(mu);
+  var ma = "#page\\:mainForm\\:categoriesTree\\:9\\:select";
+  var $mathematics = jQueryFrame(ma);
+  var o = "#page\\:mainForm\\:selectedNodesOutput span";
+  var $output = jQueryFrame(o);
+  var sn = "#page\\:mainForm\\:selectable\\:\\:0";
+  var $selectableNone = jQueryFrame(sn);
+  var ss = "#page\\:mainForm\\:selectable\\:\\:1";
+  var $selectableSingle = jQueryFrame(ss);
 
   $selectableNone.prop("checked", true).trigger("change");
 
   waitForAjax(function() {
-    return jQueryFrame(".tobago-treeSelect input").length == 0;
+    return jQueryFrame(".tobago-treeSelect input").length === 0;
   }, function() {
     assert.equal(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-    $selectableSingle = jQueryFrame($selectableSingle.selector);
+    $selectableSingle = jQueryFrame(ss);
     $selectableSingle.prop("checked", true).trigger("change");
 
     waitForAjax(function() {
@@ -39,24 +44,24 @@ QUnit.test("single: select Music, select Mathematics", function(assert) {
     }, function() {
       assert.notEqual(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-      $music = jQueryFrame($music.selector);
+      $music = jQueryFrame(mu);
       $music.prop("checked", true).trigger("change");
 
       waitForAjax(function() {
-        $output = jQueryFrame($output.selector);
-        return $output.text() == "Music"
+        $output = jQueryFrame(o);
+        return $output.text() === "Music"
       }, function() {
-        $output = jQueryFrame($output.selector);
+        $output = jQueryFrame(o);
         assert.equal($output.text(), "Music");
 
-        $mathematics = jQueryFrame($mathematics.selector);
+        $mathematics = jQueryFrame(ma);
         $mathematics.prop("checked", true).trigger("change");
 
         waitForAjax(function() {
-          $output = jQueryFrame($output.selector);
-          return $output.text() == "Mathematics"
+          $output = jQueryFrame(o);
+          return $output.text() === "Mathematics"
         }, function() {
-          $output = jQueryFrame($output.selector);
+          $output = jQueryFrame(o);
           assert.equal($output.text(), "Mathematics");
           done();
         });
@@ -71,20 +76,25 @@ QUnit.test("single: select Music, select Mathematics", function(assert) {
 QUnit.test("singleLeafOnly: select Classic, select Mathematics", function(assert) {
   assert.expect(4);
   var done = assert.async(4);
-  var $classic = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:4\\:select");
-  var $mathematics = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:9\\:select");
-  var $output = jQueryFrame("#page\\:mainForm\\:selectedNodesOutput span");
-  var $selectableNone = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:0");
-  var $selectableSingleLeafOnly = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:2");
+  var c = "#page\\:mainForm\\:categoriesTree\\:4\\:select";
+  var $classic = jQueryFrame(c);
+  var m = "#page\\:mainForm\\:categoriesTree\\:9\\:select";
+  var $mathematics = jQueryFrame(m);
+  var o = "#page\\:mainForm\\:selectedNodesOutput span";
+  var $output = jQueryFrame(o);
+  var sn = "#page\\:mainForm\\:selectable\\:\\:0";
+  var $selectableNone = jQueryFrame(sn);
+  var sslo = "#page\\:mainForm\\:selectable\\:\\:2";
+  var $selectableSingleLeafOnly = jQueryFrame(sslo);
 
   $selectableNone.prop("checked", true).trigger("change");
 
   waitForAjax(function() {
-    return jQueryFrame(".tobago-treeSelect input").length == 0;
+    return jQueryFrame(".tobago-treeSelect input").length === 0;
   }, function() {
     assert.equal(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-    $selectableSingleLeafOnly = jQueryFrame($selectableSingleLeafOnly.selector);
+    $selectableSingleLeafOnly = jQueryFrame(sslo);
     $selectableSingleLeafOnly.prop("checked", true).trigger("change");
 
     waitForAjax(function() {
@@ -92,24 +102,24 @@ QUnit.test("singleLeafOnly: select Classic, select Mathematics", function(assert
     }, function() {
       assert.notEqual(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-      $classic = jQueryFrame($classic.selector);
+      $classic = jQueryFrame(c);
       $classic.prop("checked", true).trigger("change");
 
       waitForAjax(function() {
-        $output = jQueryFrame($output.selector);
-        return $output.text() == "Classic"
+        $output = jQueryFrame(o);
+        return $output.text() === "Classic"
       }, function() {
-        $output = jQueryFrame($output.selector);
+        $output = jQueryFrame(o);
         assert.equal($output.text(), "Classic");
 
-        $mathematics = jQueryFrame($mathematics.selector);
+        $mathematics = jQueryFrame(m);
         $mathematics.prop("checked", true).trigger("change");
 
         waitForAjax(function() {
-          $output = jQueryFrame($output.selector);
-          return $output.text() == "Mathematics"
+          $output = jQueryFrame(o);
+          return $output.text() === "Mathematics"
         }, function() {
-          $output = jQueryFrame($output.selector);
+          $output = jQueryFrame(o);
           assert.equal($output.text(), "Mathematics");
           done();
         });
@@ -124,20 +134,25 @@ QUnit.test("singleLeafOnly: select Classic, select Mathematics", function(assert
 QUnit.test("multi: select Music, select Mathematics, deselect Music", function(assert) {
   assert.expect(4);
   var done = assert.async(4);
-  var $music = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:3\\:select");
-  var $mathematics = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:9\\:select");
-  var $output = jQueryFrame("#page\\:mainForm\\:selectedNodesOutput span");
-  var $selectableNone = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:0");
-  var $selectableMulti = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:3");
+  var mu = "#page\\:mainForm\\:categoriesTree\\:3\\:select";
+  var $music = jQueryFrame(mu);
+  var ma = "#page\\:mainForm\\:categoriesTree\\:9\\:select";
+  var $mathematics = jQueryFrame(ma);
+  var o = "#page\\:mainForm\\:selectedNodesOutput span";
+  var $output = jQueryFrame(o);
+  var sn = "#page\\:mainForm\\:selectable\\:\\:0";
+  var $selectableNone = jQueryFrame(sn);
+  var sm = "#page\\:mainForm\\:selectable\\:\\:3";
+  var $selectableMulti = jQueryFrame(sm);
 
   $selectableNone.prop("checked", true).trigger("change");
 
   waitForAjax(function() {
-    return jQueryFrame(".tobago-treeSelect input").length == 0;
+    return jQueryFrame(".tobago-treeSelect input").length === 0;
   }, function() {
     assert.equal(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-    $selectableMulti = jQueryFrame($selectableMulti.selector);
+    $selectableMulti = jQueryFrame(sm);
     $selectableMulti.prop("checked", true).trigger("change");
 
     waitForAjax(function() {
@@ -145,34 +160,34 @@ QUnit.test("multi: select Music, select Mathematics, deselect Music", function(a
     }, function() {
       assert.notEqual(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-      $music = jQueryFrame($music.selector);
+      $music = jQueryFrame(mu);
       $music.prop("checked", true).trigger("change");
 
       waitForAjax(function() {
-        $output = jQueryFrame($output.selector);
-        return $output.text() == "Music"
+        $output = jQueryFrame(o);
+        return $output.text() === "Music"
       }, function() {
-        $output = jQueryFrame($output.selector);
+        $output = jQueryFrame(o);
         assert.equal($output.text(), "Music");
 
-        $mathematics = jQueryFrame($mathematics.selector);
+        $mathematics = jQueryFrame(ma);
         $mathematics.prop("checked", true).trigger("change");
 
         waitForAjax(function() {
-          $output = jQueryFrame($output.selector);
-          return $output.text() == "Music, Mathematics"
+          $output = jQueryFrame(o);
+          return $output.text() === "Music, Mathematics"
         }, function() {
-          $output = jQueryFrame($output.selector);
+          $output = jQueryFrame(o);
           assert.equal($output.text(), "Music, Mathematics");
 
-          $music = jQueryFrame($music.selector);
+          $music = jQueryFrame(mu);
           $music.prop("checked", false).trigger("change");
 
           waitForAjax(function() {
-            $output = jQueryFrame($output.selector);
-            return $output.text() == "Mathematics"
+            $output = jQueryFrame(o);
+            return $output.text() === "Mathematics"
           }, function() {
-            $output = jQueryFrame($output.selector);
+            $output = jQueryFrame(o);
             assert.equal($output.text(), "Mathematics");
             done();
           });
@@ -189,20 +204,25 @@ QUnit.test("multi: select Music, select Mathematics, deselect Music", function(a
 QUnit.test("multiLeafOnly: select Classic, select Mathematics, deselect Classic", function(assert) {
   assert.expect(4);
   var done = assert.async(4);
-  var $classic = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:4\\:select");
-  var $mathematics = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:9\\:select");
-  var $output = jQueryFrame("#page\\:mainForm\\:selectedNodesOutput span");
-  var $selectableNone = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:0");
-  var $selectableMultiLeafOnly = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:4");
+  var c = "#page\\:mainForm\\:categoriesTree\\:4\\:select";
+  var $classic = jQueryFrame(c);
+  var m = "#page\\:mainForm\\:categoriesTree\\:9\\:select";
+  var $mathematics = jQueryFrame(m);
+  var o = "#page\\:mainForm\\:selectedNodesOutput span";
+  var $output = jQueryFrame(o);
+  var sn = "#page\\:mainForm\\:selectable\\:\\:0";
+  var $selectableNone = jQueryFrame(sn);
+  var smlo = "#page\\:mainForm\\:selectable\\:\\:4";
+  var $selectableMultiLeafOnly = jQueryFrame(smlo);
 
   $selectableNone.prop("checked", true).trigger("change");
 
   waitForAjax(function() {
-    return jQueryFrame(".tobago-treeSelect input").length == 0;
+    return jQueryFrame(".tobago-treeSelect input").length === 0;
   }, function() {
     assert.equal(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-    $selectableMultiLeafOnly = jQueryFrame($selectableMultiLeafOnly.selector);
+    $selectableMultiLeafOnly = jQueryFrame(smlo);
     $selectableMultiLeafOnly.prop("checked", true).trigger("change");
 
     waitForAjax(function() {
@@ -210,34 +230,34 @@ QUnit.test("multiLeafOnly: select Classic, select Mathematics, deselect Classic"
     }, function() {
       assert.notEqual(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-      $classic = jQueryFrame($classic.selector);
+      $classic = jQueryFrame(c);
       $classic.prop("checked", true).trigger("change");
 
       waitForAjax(function() {
-        $output = jQueryFrame($output.selector);
-        return $output.text() == "Classic"
+        $output = jQueryFrame(o);
+        return $output.text() === "Classic"
       }, function() {
-        $output = jQueryFrame($output.selector);
+        $output = jQueryFrame(o);
         assert.equal($output.text(), "Classic");
 
-        $mathematics = jQueryFrame($mathematics.selector);
+        $mathematics = jQueryFrame(m);
         $mathematics.prop("checked", true).trigger("change");
 
         waitForAjax(function() {
-          $output = jQueryFrame($output.selector);
-          return $output.text() == "Classic, Mathematics"
+          $output = jQueryFrame(o);
+          return $output.text() === "Classic, Mathematics"
         }, function() {
-          $output = jQueryFrame($output.selector);
+          $output = jQueryFrame(o);
           assert.equal($output.text(), "Classic, Mathematics");
 
-          $classic = jQueryFrame($classic.selector);
+          $classic = jQueryFrame(c);
           $classic.prop("checked", false).trigger("change");
 
           waitForAjax(function() {
-            $output = jQueryFrame($output.selector);
-            return $output.text() == "Mathematics"
+            $output = jQueryFrame(o);
+            return $output.text() === "Mathematics"
           }, function() {
-            $output = jQueryFrame($output.selector);
+            $output = jQueryFrame(o);
             assert.equal($output.text(), "Mathematics");
             done();
           });
@@ -254,23 +274,31 @@ QUnit.test("multiLeafOnly: select Classic, select Mathematics, deselect Classic"
 QUnit.test("multiCascade: select Music, select Mathematics, deselect Classic", function(assert) {
   assert.expect(4);
   var done = assert.async(4);
-  var $music = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:3\\:select");
-  var $classic = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:4\\:select");
-  var $pop = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:5\\:select");
-  var $world = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:6\\:select");
-  var $mathematics = jQueryFrame("#page\\:mainForm\\:categoriesTree\\:9\\:select");
-  var $output = jQueryFrame("#page\\:mainForm\\:selectedNodesOutput span");
-  var $selectableNone = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:0");
-  var $selectableMultiCascade = jQueryFrame("#page\\:mainForm\\:selectable\\:\\:5");
+  var mu = "#page\\:mainForm\\:categoriesTree\\:3\\:select";
+  var $music = jQueryFrame(mu);
+  var c = "#page\\:mainForm\\:categoriesTree\\:4\\:select";
+  var $classic = jQueryFrame(c);
+  var p = "#page\\:mainForm\\:categoriesTree\\:5\\:select";
+  var $pop = jQueryFrame(p);
+  var w = "#page\\:mainForm\\:categoriesTree\\:6\\:select";
+  var $world = jQueryFrame(w);
+  var ma = "#page\\:mainForm\\:categoriesTree\\:9\\:select";
+  var $mathematics = jQueryFrame(ma);
+  var o = "#page\\:mainForm\\:selectedNodesOutput span";
+  var $output = jQueryFrame(o);
+  var sn = "#page\\:mainForm\\:selectable\\:\\:0";
+  var $selectableNone = jQueryFrame(sn);
+  var smc = "#page\\:mainForm\\:selectable\\:\\:5";
+  var $selectableMultiCascade = jQueryFrame(smc);
 
   $selectableNone.prop("checked", true).trigger("change");
 
   waitForAjax(function() {
-    return jQueryFrame(".tobago-treeSelect input").length == 0;
+    return jQueryFrame(".tobago-treeSelect input").length === 0;
   }, function() {
     assert.equal(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-    $selectableMultiCascade = jQueryFrame($selectableMultiCascade.selector);
+    $selectableMultiCascade = jQueryFrame(smc);
     $selectableMultiCascade.prop("checked", true).trigger("change");
 
     waitForAjax(function() {
@@ -278,34 +306,34 @@ QUnit.test("multiCascade: select Music, select Mathematics, deselect Classic", f
     }, function() {
       assert.notEqual(jQueryFrame(".tobago-treeSelect input").length, 0);
 
-      $music = jQueryFrame($music.selector);
+      $music = jQueryFrame(mu);
       $music.prop("checked", true).trigger("change");
 
       waitForAjax(function() {
-        $output = jQueryFrame($output.selector);
-        return $output.text() == "Music, Classic, Pop, World"
+        $output = jQueryFrame(o);
+        return $output.text() === "Music, Classic, Pop, World"
       }, function() {
-        $output = jQueryFrame($output.selector);
+        $output = jQueryFrame(o);
         assert.equal($output.text(), "Music, Classic, Pop, World");
 
-        $mathematics = jQueryFrame($mathematics.selector);
+        $mathematics = jQueryFrame(ma);
         $mathematics.prop("checked", true).trigger("change");
 
         waitForAjax(function() {
-          $output = jQueryFrame($output.selector);
-          return $output.text() == "Music, Classic, Pop, World, Mathematics"
+          $output = jQueryFrame(o);
+          return $output.text() === "Music, Classic, Pop, World, Mathematics"
         }, function() {
-          $output = jQueryFrame($output.selector);
+          $output = jQueryFrame(o);
           assert.equal($output.text(), "Music, Classic, Pop, World, Mathematics");
 
-          $classic = jQueryFrame($classic.selector);
+          $classic = jQueryFrame(c);
           $classic.prop("checked", false).trigger("change");
 
           waitForAjax(function() {
-            $output = jQueryFrame($output.selector);
-            return $output.text() == "Music, Pop, World, Mathematics"
+            $output = jQueryFrame(o);
+            return $output.text() === "Music, Pop, World, Mathematics"
           }, function() {
-            $output = jQueryFrame($output.selector);
+            $output = jQueryFrame(o);
             assert.equal($output.text(), "Music, Pop, World, Mathematics");
             done();
           });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/00/content-validation.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/00/content-validation.test.js
index b3c1160..22deeca 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/00/content-validation.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/00/content-validation.test.js
@@ -15,20 +15,34 @@
  * limitations under the License.
  */
 
+Selectors = {};
+Selectors.testframe = "#page\\:testframe";
+Selectors.messages = "#page\\:messages .tobago-messages";
+Selectors.textarea = "#page\\:mainForm\\:required\\:textarea\\:\\:field";
+Selectors.requiredSubmit = "#page\\:mainForm\\:required\\:submit";
+Selectors.lengthField = "#page\\:mainForm\\:validateLength\\:in\\:\\:field";
+Selectors.lengthSubmit = "#page\\:mainForm\\:validateLength\\:submit";
+Selectors.rangeField = "#page\\:mainForm\\:validateRange\\:in\\:\\:field";
+Selectors.rangeSubmit = "#page\\:mainForm\\:validateRange\\:submit";
+Selectors.regexField = "#page\\:mainForm\\:regexValidation\\:in\\:\\:field";
+Selectors.regexSubmit = "#page\\:mainForm\\:regexValidation\\:submit";
+Selectors.customField = "#page\\:mainForm\\:customValidator\\:in\\:\\:field";
+Selectors.customSubmit = "#page\\:mainForm\\:customValidator\\:submit";
+
 QUnit.test("Required: Submit without content.", function (assert) {
   assert.expect(2);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $textarea = jQueryFrame("#page\\:mainForm\\:required\\:textarea\\:\\:field");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $textarea = jQueryFrame(Selectors.textarea);
   var textareaValue = $textarea.val();
-  var $submit = jQueryFrame("#page\\:mainForm\\:required\\:submit");
+  var $submit = jQueryFrame(Selectors.requiredSubmit);
 
   $textarea.val("");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     assert.equal($textarea.val(), textareaValue);
     done();
@@ -39,16 +53,16 @@ QUnit.test("Required: Submit with content.", function (assert) {
   assert.expect(2);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $textarea = jQueryFrame("#page\\:mainForm\\:required\\:textarea\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:required\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $textarea = jQueryFrame(Selectors.textarea);
+  var $submit = jQueryFrame(Selectors.requiredSubmit);
 
   $textarea.val("some content");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
-    $textarea = jQueryFrame($textarea.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
+    $textarea = jQueryFrame(Selectors.textarea);
     assert.equal($messages.length, 0);
     assert.equal($textarea.val(), "some content");
     done();
@@ -59,15 +73,15 @@ QUnit.test("Validate Length: Submit single character.", function (assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:validateLength\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:validateLength\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.lengthField);
+  var $submit = jQueryFrame(Selectors.lengthSubmit);
 
   $in.val("a");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     done();
   });
@@ -77,15 +91,15 @@ QUnit.test("Validate Length: Submit two character.", function (assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:validateLength\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:validateLength\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.lengthField);
+  var $submit = jQueryFrame(Selectors.lengthSubmit);
 
   $in.val("ab");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 0);
     done();
   });
@@ -95,15 +109,15 @@ QUnit.test("Validate Range: Submit no number.", function (assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:validateRange\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:validateRange\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.rangeField);
+  var $submit = jQueryFrame(Selectors.rangeSubmit);
 
   $in.val("no number");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     done();
   });
@@ -113,15 +127,15 @@ QUnit.test("Validate Range: Submit number '2' which is out of range.", function
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:validateRange\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:validateRange\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.rangeField);
+  var $submit = jQueryFrame(Selectors.rangeSubmit);
 
   $in.val("2");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     done();
   });
@@ -131,15 +145,15 @@ QUnit.test("Validate Range: Submit number '78' which is out of range.", function
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:validateRange\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:validateRange\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.rangeField);
+  var $submit = jQueryFrame(Selectors.rangeSubmit);
 
   $in.val("78");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     done();
   });
@@ -149,15 +163,15 @@ QUnit.test("Validate Range: Submit number '64' which is within the range.", func
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:validateRange\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:validateRange\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.rangeField);
+  var $submit = jQueryFrame(Selectors.rangeSubmit);
 
   $in.val("64");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 0);
     done();
   });
@@ -167,15 +181,15 @@ QUnit.test("Regex Validation: Submit 'T' which violates the pattern.", function
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:regexValidation\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:regexValidation\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.regexField);
+  var $submit = jQueryFrame(Selectors.regexSubmit);
 
   $in.val("T");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     done();
   });
@@ -185,15 +199,15 @@ QUnit.test("Regex Validation: Submit '3' which violates the pattern.", function
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:regexValidation\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:regexValidation\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.regexField);
+  var $submit = jQueryFrame(Selectors.regexSubmit);
 
   $in.val("3");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     done();
   });
@@ -203,15 +217,15 @@ QUnit.test("Regex Validation: Submit 'T3' which is accepted.", function (assert)
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:regexValidation\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:regexValidation\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.regexField);
+  var $submit = jQueryFrame(Selectors.regexSubmit);
 
   $in.val("T3");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 0);
     done();
   });
@@ -221,15 +235,15 @@ QUnit.test("Custom Validator: Submit rejected string.", function (assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:customValidator\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:customValidator\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.customField);
+  var $submit = jQueryFrame(Selectors.customSubmit);
 
   $in.val("java");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 1);
     done();
   });
@@ -239,15 +253,15 @@ QUnit.test("Custom Validator: Submit accepted string.", function (assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $in = jQueryFrame("#page\\:mainForm\\:customValidator\\:in\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:customValidator\\:submit");
+  var $messages = jQueryFrame(Selectors.messages);
+  var $in = jQueryFrame(Selectors.customField);
+  var $submit = jQueryFrame(Selectors.customSubmit);
 
   $in.val("tobago");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery(Selectors.testframe).on("load", function () {
+    $messages = jQueryFrame(Selectors.messages);
     assert.equal($messages.length, 0);
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/01/validation-jsr303.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/01/validation-jsr303.test.js
index d66766d..4d13293 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/01/validation-jsr303.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/06-validation/01/validation-jsr303.test.js
@@ -19,15 +19,16 @@ QUnit.test("Required: Submit without content.", function (assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $in = jQueryFrame("#page\\:mainForm\\:required\\:in\\:\\:field");
   var $submit = jQueryFrame("#page\\:mainForm\\:required\\:submit");
 
   $in.val("");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    $messages = jQueryFrame(m);
     assert.equal($messages.length, 1);
     done();
   });
@@ -37,15 +38,16 @@ QUnit.test("Required: Submit with content.", function (assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $in = jQueryFrame("#page\\:mainForm\\:required\\:in\\:\\:field");
   var $submit = jQueryFrame("#page\\:mainForm\\:required\\:submit");
 
   $in.val("some content");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    $messages = jQueryFrame(m);
     assert.equal($messages.length, 0);
     done();
   });
@@ -56,16 +58,17 @@ QUnit.test("Length: Submit single character.", function (assert) {
   var done = assert.async();
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $in = jQueryFrame("#page\\:mainForm\\:length\\:in2\\:\\:field");
   var $submit = jQueryFrame("#page\\:mainForm\\:length\\:submit2");
 
   $in.val("a");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step === 1) {
-      $messages = jQueryFrame($messages.selector);
+      $messages = jQueryFrame(m);
       assert.equal($messages.length, 1);
 
       step++;
@@ -79,16 +82,17 @@ QUnit.test("Length: Submit three characters.", function (assert) {
   var done = assert.async();
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $in = jQueryFrame("#page\\:mainForm\\:length\\:in2\\:\\:field");
   var $submit = jQueryFrame("#page\\:mainForm\\:length\\:submit2");
 
   $in.val("abc");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step === 1) {
-      $messages = jQueryFrame($messages.selector);
+      $messages = jQueryFrame(m);
       assert.equal($messages.length, 0);
 
       step++;
@@ -102,16 +106,17 @@ QUnit.test("Length: Submit five characters.", function (assert) {
   var done = assert.async();
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $in = jQueryFrame("#page\\:mainForm\\:length\\:in2\\:\\:field");
   var $submit = jQueryFrame("#page\\:mainForm\\:length\\:submit2");
 
   $in.val("abcde");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step === 1) {
-      $messages = jQueryFrame($messages.selector);
+      $messages = jQueryFrame(m);
       assert.equal($messages.length, 1);
 
       step++;
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/10-required/form-required.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/10-required/form-required.test.js
index 787278a..270a386 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/10-required/form-required.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/10-required/form-required.test.js
@@ -24,7 +24,7 @@ QUnit.test("submit inner form 1 without violations", function (assert) {
   $form1InputField.val("Alice");
   $form1SubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm1\\:in\\:\\:field");
     var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm1\\:out span");
     var $alert = jQueryFrame("#page\\:messages .alert-danger label");
@@ -49,14 +49,14 @@ QUnit.test("submit inner form 2, violate required field", function (assert) {
   assert.equal($form2InputField.val(), "");
   $form2SubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:in\\:\\:field");
     var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:out span");
     var $alert = jQueryFrame("#page\\:messages .alert-danger label");
 
     assert.equal($form2InputField.val(), "");
     assert.equal($form2OutputField.text(), form2OutputFieldValue);
-    assert.equal($alert.length, "1");
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -72,14 +72,14 @@ QUnit.test("submit inner form 2 without violations", function (assert) {
   assert.equal($form2InputField.val(), "Bob");
   $form2SubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:in\\:\\:field");
     var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:out span");
     var $alert = jQueryFrame("#page\\:messages .alert-danger label");
 
     assert.equal($form2InputField.val(), "Bob");
     assert.equal($form2OutputField.text(), "Bob");
-    assert.equal($alert.length, "0");
+    assert.equal($alert.length, 0);
 
     done();
   });
@@ -99,7 +99,7 @@ QUnit.test("submit outer form, violate both required fields", function (assert)
   $outerFormInputField.val("");
   $outerFormSubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:in\\:\\:field");
     var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:out span");
     $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
@@ -112,7 +112,7 @@ QUnit.test("submit outer form, violate both required fields", function (assert)
     assert.equal($outerFormInputField.val(), "");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    assert.equal($alert.length, "2");
+    assert.equal($alert.length, 2);
 
     done();
   });
@@ -132,7 +132,7 @@ QUnit.test("submit outer form, violate required field in form 2", function (asse
   $outerFormInputField.val("Charlie");
   $outerFormSubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:in\\:\\:field");
     var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:out span");
     $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
@@ -145,7 +145,7 @@ QUnit.test("submit outer form, violate required field in form 2", function (asse
     assert.equal($outerFormInputField.val(), "Charlie");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    assert.equal($alert.length, "1");
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -165,7 +165,7 @@ QUnit.test("submit outer form, violate required field in outer form", function (
   $outerFormInputField.val("");
   $outerFormSubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:in\\:\\:field");
     var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:out span");
     $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
@@ -178,7 +178,7 @@ QUnit.test("submit outer form, violate required field in outer form", function (
     assert.equal($outerFormInputField.val(), "");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    assert.equal($alert.length, "1");
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -197,7 +197,7 @@ QUnit.test("submit outer form without violations", function (assert) {
   $outerFormInputField.val("Grace");
   $outerFormSubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm1\\:in\\:\\:field");
     var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm1\\:out span");
     $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:innerForm2\\:in\\:\\:field");
@@ -214,7 +214,7 @@ QUnit.test("submit outer form without violations", function (assert) {
     assert.equal($outerFormInputField.val(), "Grace");
     assert.equal($outerFormOutputField.text(), "Grace");
 
-    assert.equal($alert.length, "0");
+    assert.equal($alert.length, 0);
 
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/20-ajax/form-ajax.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/20-ajax/form-ajax.test.js
index 98cd724..5d2de1e 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/20-ajax/form-ajax.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/20-ajax/form-ajax.test.js
@@ -15,30 +15,44 @@
  * limitations under the License.
  */
 
+Selectors = {};
+Selectors.form1InputField = "#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field";
+Selectors.form1OutputField = "#page\\:mainForm\\:outerForm\\:form1\\:out span";
+Selectors.form1Submit = "#page\\:mainForm\\:outerForm\\:form1\\:submit";
+Selectors.form2InputField = "#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field";
+Selectors.form2OutputField = "#page\\:mainForm\\:outerForm\\:form2\\:out span";
+Selectors.form2Submit = "#page\\:mainForm\\:outerForm\\:form2\\:submit";
+Selectors.outerFormInputField = "#page\\:mainForm\\:outerForm\\:in\\:\\:field";
+Selectors.outerFormOutputField = "#page\\:mainForm\\:outerForm\\:out span";
+Selectors.outerFormSubmitOuterValue = "#page\\:mainForm\\:outerForm\\:submitOuterValue";
+Selectors.outerFormSubmit = "#page\\:mainForm\\:outerForm\\:submit";
+Selectors.outerFormSubmitInnerForms = "#page\\:mainForm\\:outerForm\\:submitInnerForms";
+Selectors.alert = "#page\\:messages .alert-danger label";
+
 QUnit.test("submit inner form 1 without violations", function (assert) {
   assert.expect(3);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:submit");
+  var $button = jQueryFrame(Selectors.form1Submit);
 
   $form1InputField.val("Alice");
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
     return $form1InputField.val() == "Alice" && $form1OutputField.text() == "Alice";
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
 
     assert.equal($form1InputField.val(), "Alice");
     assert.equal($form1OutputField.text(), "Alice");
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "0");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 0);
 
     done();
   });
@@ -47,10 +61,10 @@ QUnit.test("submit inner form 1 without violations", function (assert) {
 QUnit.test("submit inner form 2, violate required field", function (assert) {
   assert.expect(3);
   var done = assert.async();
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:submit");
+  var $button = jQueryFrame(Selectors.form2Submit);
 
   var form2OutputFieldValue = $form2OutputField.text();
 
@@ -58,18 +72,18 @@ QUnit.test("submit inner form 2, violate required field", function (assert) {
   $button.click();
 
   waitForAjax(function () {
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    return $form2InputField.val() == "" && $form2OutputField.text() == form2OutputFieldValue;
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    return $form2InputField.val() === "" && $form2OutputField.text() === form2OutputFieldValue;
   }, function () {
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
 
     assert.equal($form2InputField.val(), "");
     assert.equal($form2OutputField.text(), form2OutputFieldValue);
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "1");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -78,27 +92,27 @@ QUnit.test("submit inner form 2, violate required field", function (assert) {
 QUnit.test("submit inner form 2 without violations", function (assert) {
   assert.expect(3);
   var done = assert.async();
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:submit");
+  var $button = jQueryFrame(Selectors.form2Submit);
 
   $form2InputField.val("Bob");
   $button.click();
 
   waitForAjax(function () {
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    return $form2InputField.val() == "Bob" && $form2OutputField.text() == "Bob";
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    return $form2InputField.val() === "Bob" && $form2OutputField.text() === "Bob";
   }, function () {
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
 
     assert.equal($form2InputField.val(), "Bob");
     assert.equal($form2OutputField.text(), "Bob");
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "0");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 0);
 
     done();
   });
@@ -107,14 +121,14 @@ QUnit.test("submit inner form 2 without violations", function (assert) {
 QUnit.test("submit outer form, violate both required fields", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submit");
+  var $button = jQueryFrame(Selectors.outerFormSubmit);
 
   var form1OutputFieldValue = $form1OutputField.text();
   var form2OutputFieldValue = $form2OutputField.text();
@@ -126,25 +140,25 @@ QUnit.test("submit outer form, violate both required fields", function (assert)
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Charlie"
-        && $form1OutputField.text() == form1OutputFieldValue
-        && $form2InputField.val() == ""
-        && $form2OutputField.text() == form2OutputFieldValue
-        && $outerFormInputField.val() == ""
-        && $outerFormOutputField.text() == outerFormOutputFieldValue;
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Charlie"
+        && $form1OutputField.text() === form1OutputFieldValue
+        && $form2InputField.val() === ""
+        && $form2OutputField.text() === form2OutputFieldValue
+        && $outerFormInputField.val() === ""
+        && $outerFormOutputField.text() === outerFormOutputFieldValue;
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Charlie");
     assert.equal($form1OutputField.text(), form1OutputFieldValue);
@@ -153,8 +167,8 @@ QUnit.test("submit outer form, violate both required fields", function (assert)
     assert.equal($outerFormInputField.val(), "");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "2");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 2);
 
     done();
   });
@@ -163,14 +177,14 @@ QUnit.test("submit outer form, violate both required fields", function (assert)
 QUnit.test("submit outer form, violate required field in form 2", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submit");
+  var $button = jQueryFrame(Selectors.outerFormSubmit);
 
   var form1OutputFieldValue = $form1OutputField.text();
   var form2OutputFieldValue = $form2OutputField.text();
@@ -182,25 +196,25 @@ QUnit.test("submit outer form, violate required field in form 2", function (asse
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Dave"
-        && $form1OutputField.text() == form1OutputFieldValue
-        && $form2InputField.val() == ""
-        && $form2OutputField.text() == form2OutputFieldValue
-        && $outerFormInputField.val() == "Eve"
-        && $outerFormOutputField.text() == outerFormOutputFieldValue;
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Dave"
+        && $form1OutputField.text() === form1OutputFieldValue
+        && $form2InputField.val() === ""
+        && $form2OutputField.text() === form2OutputFieldValue
+        && $outerFormInputField.val() === "Eve"
+        && $outerFormOutputField.text() === outerFormOutputFieldValue;
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Dave");
     assert.equal($form1OutputField.text(), form1OutputFieldValue);
@@ -209,8 +223,8 @@ QUnit.test("submit outer form, violate required field in form 2", function (asse
     assert.equal($outerFormInputField.val(), "Eve");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "1");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -219,14 +233,14 @@ QUnit.test("submit outer form, violate required field in form 2", function (asse
 QUnit.test("submit outer form, violate required field in outer form", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submit");
+  var $button = jQueryFrame(Selectors.outerFormSubmit);
 
   var form1OutputFieldValue = $form1OutputField.text();
   var form2OutputFieldValue = $form2OutputField.text();
@@ -238,25 +252,25 @@ QUnit.test("submit outer form, violate required field in outer form", function (
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Frank"
-        && $form1OutputField.text() == form1OutputFieldValue
-        && $form2InputField.val() == "Grace"
-        && $form2OutputField.text() == form2OutputFieldValue
-        && $outerFormInputField.val() == ""
-        && $outerFormOutputField.text() == outerFormOutputFieldValue;
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Frank"
+        && $form1OutputField.text() === form1OutputFieldValue
+        && $form2InputField.val() === "Grace"
+        && $form2OutputField.text() === form2OutputFieldValue
+        && $outerFormInputField.val() === ""
+        && $outerFormOutputField.text() === outerFormOutputFieldValue;
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Frank");
     assert.equal($form1OutputField.text(), form1OutputFieldValue);
@@ -265,8 +279,8 @@ QUnit.test("submit outer form, violate required field in outer form", function (
     assert.equal($outerFormInputField.val(), "");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "1");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -275,14 +289,14 @@ QUnit.test("submit outer form, violate required field in outer form", function (
 QUnit.test("submit outer form without violations", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submit");
+  var $button = jQueryFrame(Selectors.outerFormSubmit);
 
   $form1InputField.val("Hank");
   $form2InputField.val("Irene");
@@ -290,25 +304,25 @@ QUnit.test("submit outer form without violations", function (assert) {
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Hank"
-        && $form1OutputField.text() == "Hank"
-        && $form2InputField.val() == "Irene"
-        && $form2OutputField.text() == "Irene"
-        && $outerFormInputField.val() == "John"
-        && $outerFormOutputField.text() == "John";
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Hank"
+        && $form1OutputField.text() === "Hank"
+        && $form2InputField.val() === "Irene"
+        && $form2OutputField.text() === "Irene"
+        && $outerFormInputField.val() === "John"
+        && $outerFormOutputField.text() === "John";
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Hank");
     assert.equal($form1OutputField.text(), "Hank");
@@ -317,8 +331,8 @@ QUnit.test("submit outer form without violations", function (assert) {
     assert.equal($outerFormInputField.val(), "John");
     assert.equal($outerFormOutputField.text(), "John");
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "0");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 0);
 
     done();
   });
@@ -327,14 +341,14 @@ QUnit.test("submit outer form without violations", function (assert) {
 QUnit.test("submit inner forms, violate required field in form 2", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submitInnerForms");
+  var $button = jQueryFrame(Selectors.outerFormSubmitInnerForms);
 
   var form1OutputFieldValue = $form1OutputField.text();
   var form2OutputFieldValue = $form2OutputField.text();
@@ -346,25 +360,25 @@ QUnit.test("submit inner forms, violate required field in form 2", function (ass
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Kate"
-    && $form1OutputField.text() == form1OutputFieldValue
-    && $form2InputField.val() == ""
-    && $form2OutputField.text() == form2OutputFieldValue
-    && $outerFormInputField.val() == "Leonard"
-    && $outerFormOutputField.text(), outerFormOutputFieldValue;
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Kate"
+    && $form1OutputField.text() === form1OutputFieldValue
+    && $form2InputField.val() === ""
+    && $form2OutputField.text() === form2OutputFieldValue
+    && $outerFormInputField.val() === "Leonard"
+    && $outerFormOutputField.text() === outerFormOutputFieldValue;
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Kate");
     assert.equal($form1OutputField.text(), form1OutputFieldValue);
@@ -373,8 +387,8 @@ QUnit.test("submit inner forms, violate required field in form 2", function (ass
     assert.equal($outerFormInputField.val(), "Leonard");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "1");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -383,14 +397,14 @@ QUnit.test("submit inner forms, violate required field in form 2", function (ass
 QUnit.test("submit inner forms without violations", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submitInnerForms");
+  var $button = jQueryFrame(Selectors.outerFormSubmitInnerForms);
 
   var outerFormOutputFieldValue = $outerFormOutputField.text();
 
@@ -400,25 +414,25 @@ QUnit.test("submit inner forms without violations", function (assert) {
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Mike"
-        && $form1OutputField.text() == "Mike"
-        && $form2InputField.val() == "Neil"
-        && $form2OutputField.text() == "Neil"
-        && $outerFormInputField.val() == ""
-        && $outerFormOutputField.text() == outerFormOutputFieldValue;
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Mike"
+        && $form1OutputField.text() === "Mike"
+        && $form2InputField.val() === "Neil"
+        && $form2OutputField.text() === "Neil"
+        && $outerFormInputField.val() === ""
+        && $outerFormOutputField.text() === outerFormOutputFieldValue;
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Mike");
     assert.equal($form1OutputField.text(), "Mike");
@@ -427,8 +441,8 @@ QUnit.test("submit inner forms without violations", function (assert) {
     assert.equal($outerFormInputField.val(), "");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "0");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 0);
 
     done();
   });
@@ -437,14 +451,14 @@ QUnit.test("submit inner forms without violations", function (assert) {
 QUnit.test("submit outer value, violate required field", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submitOuterValue");
+  var $button = jQueryFrame(Selectors.outerFormSubmitOuterValue);
 
   var form1OutputFieldValue = $form1OutputField.text();
   var form2OutputFieldValue = $form2OutputField.text();
@@ -456,25 +470,25 @@ QUnit.test("submit outer value, violate required field", function (assert) {
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Oscar"
-        && $form1OutputField.text() == form1OutputFieldValue
-        && $form2InputField.val() == "Penny"
-        && $form2OutputField.text() == form2OutputFieldValue
-        && $outerFormInputField.val() == ""
-        && $outerFormOutputField.text() == outerFormOutputFieldValue;
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Oscar"
+        && $form1OutputField.text() === form1OutputFieldValue
+        && $form2InputField.val() === "Penny"
+        && $form2OutputField.text() === form2OutputFieldValue
+        && $outerFormInputField.val() === ""
+        && $outerFormOutputField.text() === outerFormOutputFieldValue;
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Oscar");
     assert.equal($form1OutputField.text(), form1OutputFieldValue);
@@ -483,8 +497,8 @@ QUnit.test("submit outer value, violate required field", function (assert) {
     assert.equal($outerFormInputField.val(), "");
     assert.equal($outerFormOutputField.text(), outerFormOutputFieldValue);
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "1");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 1);
 
     done();
   });
@@ -493,14 +507,14 @@ QUnit.test("submit outer value, violate required field", function (assert) {
 QUnit.test("submit outer value without violations", function (assert) {
   assert.expect(7);
   var done = assert.async();
-  var $form1InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:in\\:\\:field");
-  var $form1OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form1\\:out span");
-  var $form2InputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:in\\:\\:field");
-  var $form2OutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:form2\\:out span");
-  var $outerFormInputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:in\\:\\:field");
-  var $outerFormOutputField = jQueryFrame("#page\\:mainForm\\:outerForm\\:out span");
+  var $form1InputField = jQueryFrame(Selectors.form1InputField);
+  var $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+  var $form2InputField = jQueryFrame(Selectors.form2InputField);
+  var $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+  var $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+  var $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
-  var $button = jQueryFrame("#page\\:mainForm\\:outerForm\\:submitOuterValue");
+  var $button = jQueryFrame(Selectors.outerFormSubmitOuterValue);
 
   var form1OutputFieldValue = $form1OutputField.text();
   var form2OutputFieldValue = $form2OutputField.text();
@@ -511,25 +525,25 @@ QUnit.test("submit outer value without violations", function (assert) {
   $button.click();
 
   waitForAjax(function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
-    return $form1InputField.val() == "Quin"
-        && $form1OutputField.text() == form1OutputFieldValue
-        && $form2InputField.val() == "Sue"
-        && $form2OutputField.text() == form2OutputFieldValue
-        && $outerFormInputField.val() == "Ted"
-        && $outerFormOutputField.text() == "Ted";
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
+    return $form1InputField.val() === "Quin"
+        && $form1OutputField.text() === form1OutputFieldValue
+        && $form2InputField.val() === "Sue"
+        && $form2OutputField.text() === form2OutputFieldValue
+        && $outerFormInputField.val() === "Ted"
+        && $outerFormOutputField.text() === "Ted";
   }, function () {
-    $form1InputField = jQueryFrame($form1InputField.selector);
-    $form1OutputField = jQueryFrame($form1OutputField.selector);
-    $form2InputField = jQueryFrame($form2InputField.selector);
-    $form2OutputField = jQueryFrame($form2OutputField.selector);
-    $outerFormInputField = jQueryFrame($outerFormInputField.selector);
-    $outerFormOutputField = jQueryFrame($outerFormOutputField.selector);
+    $form1InputField = jQueryFrame(Selectors.form1InputField);
+    $form1OutputField = jQueryFrame(Selectors.form1OutputField);
+    $form2InputField = jQueryFrame(Selectors.form2InputField);
+    $form2OutputField = jQueryFrame(Selectors.form2OutputField);
+    $outerFormInputField = jQueryFrame(Selectors.outerFormInputField);
+    $outerFormOutputField = jQueryFrame(Selectors.outerFormOutputField);
 
     assert.equal($form1InputField.val(), "Quin");
     assert.equal($form1OutputField.text(), form1OutputFieldValue);
@@ -538,8 +552,8 @@ QUnit.test("submit outer value without violations", function (assert) {
     assert.equal($outerFormInputField.val(), "Ted");
     assert.equal($outerFormOutputField.text(), "Ted");
 
-    var $alert = jQueryFrame("#page\\:messages .alert-danger label");
-    assert.equal($alert.length, "0");
+    var $alert = jQueryFrame(Selectors.alert);
+    assert.equal($alert.length, 0);
 
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/form.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/form.test.js
index d960679..80c5599 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/form.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/08-form/form.test.js
@@ -30,7 +30,7 @@ QUnit.test("submit form 1", function (assert) {
 
   $form1SubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form1InputField = jQueryFrame("#page\\:mainForm\\:form1\\:in\\:\\:field");
     var $form1OutputField = jQueryFrame("#page\\:mainForm\\:form1\\:out span");
     $form2InputField = jQueryFrame("#page\\:mainForm\\:form2\\:in\\:\\:field");
@@ -60,7 +60,7 @@ QUnit.test("submit form 2", function (assert) {
 
   $form2SubmitButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     $form1InputField = jQueryFrame("#page\\:mainForm\\:form1\\:in\\:\\:field");
     var $form1OutputField = jQueryFrame("#page\\:mainForm\\:form1\\:out span");
     $form2InputField = jQueryFrame("#page\\:mainForm\\:form2\\:in\\:\\:field");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/51-for-each/for-each.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/51-for-each/for-each.test.js
index 224868a..72ba45c 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/51-for-each/for-each.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/51-for-each/for-each.test.js
@@ -20,24 +20,31 @@ QUnit.test("Add a river and reset.", function (assert) {
   var done = assert.async(3);
   var step = 1;
 
-  var $name = jQueryFrame("#page\\:mainForm\\:add\\:inName\\:\\:field");
-  var $length = jQueryFrame("#page\\:mainForm\\:add\\:inLength\\:\\:field");
-  var $discharge = jQueryFrame("#page\\:mainForm\\:add\\:inDischarge\\:\\:field");
-  var $add = jQueryFrame("#page\\:mainForm\\:add\\:button");
-  var $reset = jQueryFrame("#page\\:mainForm\\:reset\\:button");
-  var $forEachBoxes = jQueryFrame("#page\\:mainForm\\:forEach .tobago-box");
-  var $uiRepeatSections = jQueryFrame("#page\\:mainForm\\:uiRepeat .tobago-section");
+  var n = "#page\\:mainForm\\:add\\:inName\\:\\:field";
+  var $name = jQueryFrame(n);
+  var l = "#page\\:mainForm\\:add\\:inLength\\:\\:field";
+  var $length = jQueryFrame(l);
+  var d = "#page\\:mainForm\\:add\\:inDischarge\\:\\:field";
+  var $discharge = jQueryFrame(d);
+  var a = "#page\\:mainForm\\:add\\:button";
+  var $add = jQueryFrame(a);
+  var r = "#page\\:mainForm\\:reset\\:button";
+  var $reset = jQueryFrame(r);
+  var feb = "#page\\:mainForm\\:forEach .tobago-box";
+  var $forEachBoxes = jQueryFrame(feb);
+  var urs = "#page\\:mainForm\\:uiRepeat .tobago-section";
+  var $uiRepeatSections = jQueryFrame(urs);
 
   $reset.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $name = jQueryFrame($name.selector);
-      $length = jQueryFrame($length.selector);
-      $discharge = jQueryFrame($discharge.selector);
-      $add = jQueryFrame($add.selector);
-      $forEachBoxes = jQueryFrame($forEachBoxes.selector);
-      $uiRepeatSections = jQueryFrame($uiRepeatSections.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $name = jQueryFrame(n);
+      $length = jQueryFrame(l);
+      $discharge = jQueryFrame(d);
+      $add = jQueryFrame(a);
+      $forEachBoxes = jQueryFrame(feb);
+      $uiRepeatSections = jQueryFrame(urs);
 
       assert.equal($forEachBoxes.length, 3);
       assert.equal($uiRepeatSections.length, 3);
@@ -48,10 +55,10 @@ QUnit.test("Add a river and reset.", function (assert) {
       $add.click();
 
       done();
-    } else if (step == 2) {
-      $reset = jQueryFrame($reset.selector);
-      $forEachBoxes = jQueryFrame($forEachBoxes.selector);
-      $uiRepeatSections = jQueryFrame($uiRepeatSections.selector);
+    } else if (step === 2) {
+      $reset = jQueryFrame(r);
+      $forEachBoxes = jQueryFrame(feb);
+      $uiRepeatSections = jQueryFrame(urs);
 
       assert.equal($forEachBoxes.length, 4);
       assert.equal($uiRepeatSections.length, 4);
@@ -59,9 +66,9 @@ QUnit.test("Add a river and reset.", function (assert) {
       $reset.click();
 
       done();
-    } else if (step == 3) {
-      $forEachBoxes = jQueryFrame($forEachBoxes.selector);
-      $uiRepeatSections = jQueryFrame($uiRepeatSections.selector);
+    } else if (step === 3) {
+      $forEachBoxes = jQueryFrame(feb);
+      $uiRepeatSections = jQueryFrame(urs);
 
       assert.equal($forEachBoxes.length, 3);
       assert.equal($uiRepeatSections.length, 3);
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/00-collapsible-box/collapsible-box.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/00-collapsible-box/collapsible-box.test.js
index 00deee4..a4c9c6a 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/00-collapsible-box/collapsible-box.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/00-collapsible-box/collapsible-box.test.js
@@ -20,24 +20,27 @@ QUnit.test("Simple Collapsible Box: show -> hide transition", function (assert)
   var done = assert.async(2);
   var step = 1;
 
-  var $show = jQueryFrame("#page\\:mainForm\\:controller\\:show");
-  var $hide = jQueryFrame("#page\\:mainForm\\:controller\\:hide");
-  var $content = jQueryFrame("#page\\:mainForm\\:controller\\:content");
+  var s = "#page\\:mainForm\\:controller\\:show";
+  var $show = jQueryFrame(s);
+  var h = "#page\\:mainForm\\:controller\\:hide";
+  var $hide = jQueryFrame(h);
+  var c = "#page\\:mainForm\\:controller\\:content";
+  var $content = jQueryFrame(c);
 
   $show.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $hide = jQueryFrame($hide.selector);
-      $content = jQueryFrame($content.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $hide = jQueryFrame(h);
+      $content = jQueryFrame(c);
 
       assert.equal($content.length, 1);
       $hide.click();
 
       step++;
       done();
-    } else if (step == 2) {
-      $content = jQueryFrame($content.selector);
+    } else if (step === 2) {
+      $content = jQueryFrame(c);
 
       assert.equal($content.length, 0);
 
@@ -52,24 +55,27 @@ QUnit.test("Simple Collapsible Box: hide -> show transition", function (assert)
   var done = assert.async(2);
   var step = 1;
 
-  var $show = jQueryFrame("#page\\:mainForm\\:controller\\:show");
-  var $hide = jQueryFrame("#page\\:mainForm\\:controller\\:hide");
-  var $content = jQueryFrame("#page\\:mainForm\\:controller\\:content");
+  var s = "#page\\:mainForm\\:controller\\:show";
+  var $show = jQueryFrame(s)  ;
+  var h = "#page\\:mainForm\\:controller\\:hide";
+  var $hide = jQueryFrame(h);
+  var c = "#page\\:mainForm\\:controller\\:content";
+  var $content = jQueryFrame(c);
 
   $hide.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $show = jQueryFrame($show.selector);
-      $content = jQueryFrame($content.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $show = jQueryFrame(s);
+      $content = jQueryFrame(c);
 
       assert.equal($content.length, 0);
       $show.click();
 
       step++;
       done();
-    } else if (step == 2) {
-      $content = jQueryFrame($content.selector);
+    } else if (step === 2) {
+      $content = jQueryFrame(c);
 
       assert.equal($content.length, 1);
 
@@ -84,19 +90,23 @@ QUnit.test("Full Server Request: open both boxes", function (assert) {
   var done = assert.async(2);
   var step = 1;
 
-  var $show1 = jQueryFrame("#page\\:mainForm\\:server\\:show1");
-  var $show2 = jQueryFrame("#page\\:mainForm\\:server\\:show2");
-  var $content1 = jQueryFrame("#page\\:mainForm\\:server\\:content1");
-  var $content2 = jQueryFrame("#page\\:mainForm\\:server\\:content2");
+  var s1 = "#page\\:mainForm\\:server\\:show1";
+  var $show1 = jQueryFrame(s1);
+  var s2 = "#page\\:mainForm\\:server\\:show2";
+  var $show2 = jQueryFrame(s2);
+  var c1 = "#page\\:mainForm\\:server\\:content1";
+  var $content1 = jQueryFrame(c1);
+  var c2 = "#page\\:mainForm\\:server\\:content2";
+  var $content2 = jQueryFrame(c2);
   var content2Length = $content2.length;
 
   $show1.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $show2 = jQueryFrame($show2.selector);
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $show2 = jQueryFrame(s2);
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 1);
       assert.equal($content2.length, content2Length);
@@ -104,9 +114,9 @@ QUnit.test("Full Server Request: open both boxes", function (assert) {
 
       step++;
       done();
-    } else if (step == 2) {
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+    } else if (step === 2) {
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 1);
       assert.equal($content2.length, 1);
@@ -122,19 +132,23 @@ QUnit.test("Full Server Request: open box 1, close box 2", function (assert) {
   var done = assert.async(2);
   var step = 1;
 
-  var $show1 = jQueryFrame("#page\\:mainForm\\:server\\:show1");
-  var $hide2 = jQueryFrame("#page\\:mainForm\\:server\\:hide2");
-  var $content1 = jQueryFrame("#page\\:mainForm\\:server\\:content1");
-  var $content2 = jQueryFrame("#page\\:mainForm\\:server\\:content2");
+  var s1 = "#page\\:mainForm\\:server\\:show1";
+  var $show1 = jQueryFrame(s1);
+  var h2 = "#page\\:mainForm\\:server\\:hide2";
+  var $hide2 = jQueryFrame(h2);
+  var c1 = "#page\\:mainForm\\:server\\:content1";
+  var $content1 = jQueryFrame(c1);
+  var c2 = "#page\\:mainForm\\:server\\:content2";
+  var $content2 = jQueryFrame(c2);
   var content2Length = $content2.length;
 
   $show1.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $hide2 = jQueryFrame($hide2.selector);
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $hide2 = jQueryFrame(h2);
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 1);
       assert.equal($content2.length, content2Length);
@@ -142,9 +156,9 @@ QUnit.test("Full Server Request: open box 1, close box 2", function (assert) {
 
       step++;
       done();
-    } else if (step == 2) {
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+    } else if (step === 2) {
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 1);
       assert.equal($content2.length, 0);
@@ -160,19 +174,23 @@ QUnit.test("Full Server Request: close box 1, open box 2", function (assert) {
   var done = assert.async(2);
   var step = 1;
 
-  var $hide1 = jQueryFrame("#page\\:mainForm\\:server\\:hide1");
-  var $show2 = jQueryFrame("#page\\:mainForm\\:server\\:show2");
-  var $content1 = jQueryFrame("#page\\:mainForm\\:server\\:content1");
-  var $content2 = jQueryFrame("#page\\:mainForm\\:server\\:content2");
+  var h1 = "#page\\:mainForm\\:server\\:hide1";
+  var $hide1 = jQueryFrame(h1);
+  var s2 = "#page\\:mainForm\\:server\\:show2";
+  var $show2 = jQueryFrame(s2);
+  var c1 = "#page\\:mainForm\\:server\\:content1";
+  var $content1 = jQueryFrame(c1);
+  var c2 = "#page\\:mainForm\\:server\\:content2";
+  var $content2 = jQueryFrame(c2);
   var content2Length = $content2.length;
 
   $hide1.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $show2 = jQueryFrame($show2.selector);
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $show2 = jQueryFrame(s2);
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 0);
       assert.equal($content2.length, content2Length);
@@ -180,9 +198,9 @@ QUnit.test("Full Server Request: close box 1, open box 2", function (assert) {
 
       step++;
       done();
-    } else if (step == 2) {
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+    } else if (step === 2) {
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 0);
       assert.equal($content2.length, 1);
@@ -198,19 +216,23 @@ QUnit.test("Full Server Request: close both boxes", function (assert) {
   var done = assert.async(2);
   var step = 1;
 
-  var $hide1 = jQueryFrame("#page\\:mainForm\\:server\\:hide1");
-  var $hide2 = jQueryFrame("#page\\:mainForm\\:server\\:hide2");
-  var $content1 = jQueryFrame("#page\\:mainForm\\:server\\:content1");
-  var $content2 = jQueryFrame("#page\\:mainForm\\:server\\:content2");
+  var h1 = "#page\\:mainForm\\:server\\:hide1";
+  var $hide1 = jQueryFrame(h1);
+  var h2 = "#page\\:mainForm\\:server\\:hide2";
+  var $hide2 = jQueryFrame(h2);
+  var c1 = "#page\\:mainForm\\:server\\:content1";
+  var $content1 = jQueryFrame(c1);
+  var c2 = "#page\\:mainForm\\:server\\:content2";
+  var $content2 = jQueryFrame(c2);
   var content2Length = $content2.length;
 
   $hide1.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $hide2 = jQueryFrame($hide2.selector);
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $hide2 = jQueryFrame(h2);
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 0);
       assert.equal($content2.length, content2Length);
@@ -218,9 +240,9 @@ QUnit.test("Full Server Request: close both boxes", function (assert) {
 
       step++;
       done();
-    } else if (step == 2) {
-      $content1 = jQueryFrame($content1.selector);
-      $content2 = jQueryFrame($content2.selector);
+    } else if (step === 2) {
+      $content1 = jQueryFrame(c1);
+      $content2 = jQueryFrame(c2);
 
       assert.equal($content1.length, 0);
       assert.equal($content2.length, 0);
@@ -263,7 +285,8 @@ QUnit.test("Client Sided: hide content and submit empty string", function (asser
   assert.expect(2);
   var done = assert.async();
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $show = jQueryFrame("#page\\:mainForm\\:client\\:showNoRequestBox");
   var $hide = jQueryFrame("#page\\:mainForm\\:client\\:hideNoRequestBox");
   var $box = jQueryFrame("#page\\:mainForm\\:client\\:noRequestBox");
@@ -276,8 +299,8 @@ QUnit.test("Client Sided: hide content and submit empty string", function (asser
   $in.val("");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    $messages = jQueryFrame($messages.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    $messages = jQueryFrame(m);
     assert.equal($messages.length, 1);
     done();
   });
@@ -288,21 +311,24 @@ QUnit.test("Ajax: show -> hide transition", function (assert) {
   var done = assert.async(2);
   var step = 1;
 
-  var $show = jQueryFrame("#page\\:mainForm\\:ajax\\:showAjaxBox");
-  var $hide = jQueryFrame("#page\\:mainForm\\:ajax\\:hideAjaxBox");
-  var $in = jQueryFrame("#page\\:mainForm\\:ajax\\:inAjaxBox\\:\\:field");
+  var s = "#page\\:mainForm\\:ajax\\:showAjaxBox";
+  var $show = jQueryFrame(s);
+  var h = "#page\\:mainForm\\:ajax\\:hideAjaxBox";
+  var $hide = jQueryFrame(h);
+  var i = "#page\\:mainForm\\:ajax\\:inAjaxBox\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
 
   waitForAjax(function () {
-    $in = jQueryFrame($in.selector);
+    $in = jQueryFrame(i);
     console.log("step: " + step + " active: " + jQuery.active);
-    return step == 1 && jQuery.active == 0;
+    return step === 1 && jQuery.active === 0;
   }, function () {
-    $hide = jQueryFrame($hide.selector);
-    $in = jQueryFrame($in.selector);
+    $hide = jQueryFrame(h);
+    $in = jQueryFrame(i);
 
-    console.log("$hide.selector: " + $hide.selector);
+    console.log("$hide selector: " + h);
     assert.equal($in.length, 1);
     $hide.click();
 
@@ -311,10 +337,10 @@ QUnit.test("Ajax: show -> hide transition", function (assert) {
   });
 
   waitForAjax(function () {
-    $in = jQueryFrame($in.selector);
-    return step == 2 && $in.length == 0;
+    $in = jQueryFrame(i);
+    return step === 2 && $in.length === 0;
   }, function () {
-    $in = jQueryFrame($in.selector);
+    $in = jQueryFrame(i);
     assert.equal($in.length, 0);
     done();
   });
@@ -326,18 +352,21 @@ QUnit.test("Ajax: hide -> show transition", function (assert) {
   var done = assert.async(2);
   var step = 1;
 
-  var $show = jQueryFrame("#page\\:mainForm\\:ajax\\:showAjaxBox");
-  var $hide = jQueryFrame("#page\\:mainForm\\:ajax\\:hideAjaxBox");
-  var $in = jQueryFrame("#page\\:mainForm\\:ajax\\:inAjaxBox\\:\\:field");
+  var s = "#page\\:mainForm\\:ajax\\:showAjaxBox";
+  var $show = jQueryFrame(s);
+  var h = "#page\\:mainForm\\:ajax\\:hideAjaxBox";
+  var $hide = jQueryFrame(h);
+  var i = "#page\\:mainForm\\:ajax\\:inAjaxBox\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $hide.click();
 
   waitForAjax(function () {
-    $in = jQueryFrame($in.selector);
-    return step == 1 && $in.length == 0;
+    $in = jQueryFrame(i);
+    return step === 1 && $in.length === 0;
   }, function () {
-    $show = jQueryFrame($show.selector);
-    $in = jQueryFrame($in.selector);
+    $show = jQueryFrame(s);
+    $in = jQueryFrame(i);
 
     assert.equal($in.length, 0);
     $show.click();
@@ -347,10 +376,10 @@ QUnit.test("Ajax: hide -> show transition", function (assert) {
   });
 
   waitForAjax(function () {
-    $in = jQueryFrame($in.selector);
-    return step == 2 && $in.length == 1;
+    $in = jQueryFrame(i);
+    return step === 2 && $in.length === 1;
   }, function () {
-    $in = jQueryFrame($in.selector);
+    $in = jQueryFrame(i);
     assert.equal($in.length, 1);
     done();
   });
@@ -361,20 +390,24 @@ QUnit.test("Ajax: hide content and submit empty string", function (assert) {
   var done = assert.async(3);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $show = jQueryFrame("#page\\:mainForm\\:ajax\\:showAjaxBox");
-  var $hide = jQueryFrame("#page\\:mainForm\\:ajax\\:hideAjaxBox");
-  var $in = jQueryFrame("#page\\:mainForm\\:ajax\\:inAjaxBox\\:\\:field");
-  var $submit = jQueryFrame("#page\\:mainForm\\:ajax\\:submitAjaxBox");
+  var h = "#page\\:mainForm\\:ajax\\:hideAjaxBox";
+  var $hide = jQueryFrame(h);
+  var i = "#page\\:mainForm\\:ajax\\:inAjaxBox\\:\\:field";
+  var $in = jQueryFrame(i);
+  var s = "#page\\:mainForm\\:ajax\\:submitAjaxBox";
+  var $submit = jQueryFrame(s);
 
   $show.click();
 
   waitForAjax(function () {
-    $in = jQueryFrame($in.selector);
+    $in = jQueryFrame(i);
     return step == 1 && $in.length == 1;
   }, function () {
-    $hide = jQueryFrame($hide.selector);
-    $in = jQueryFrame($in.selector);
+    $hide = jQueryFrame(h);
+    $in = jQueryFrame(i);
 
     assert.equal($in.length, 1);
     $in.val("");
@@ -385,11 +418,11 @@ QUnit.test("Ajax: hide content and submit empty string", function (assert) {
   });
 
   waitForAjax(function () {
-    $in = jQueryFrame($in.selector);
+    $in = jQueryFrame(i);
     return step == 2 && $in.length == 0;
   }, function () {
-    $in = jQueryFrame($in.selector);
-    $submit = jQueryFrame($submit.selector);
+    $in = jQueryFrame(i);
+    $submit = jQueryFrame(s);
 
     assert.equal($in.length, 0);
     $submit.click();
@@ -398,9 +431,9 @@ QUnit.test("Ajax: hide content and submit empty string", function (assert) {
     done();
   });
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 3) {
+      $messages = jQueryFrame(m);
       assert.equal($messages.length, 0);
       done();
     }
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/10-collapsible-popup/collapsible-popup.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/10-collapsible-popup/collapsible-popup.test.js
index 75fb6a4..3231474 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/10-collapsible-popup/collapsible-popup.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/10-collapsible-popup/collapsible-popup.test.js
@@ -20,19 +20,24 @@ QUnit.test("Simple Popup", function (assert) {
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var messagesSelector = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(messagesSelector);
   var $open = jQueryFrame("#page\\:mainForm\\:simple\\:open1");
-  var $submitOnPage = jQueryFrame("#page\\:mainForm\\:simple\\:submitOnPage1");
-  var $in = jQueryFrame("#page\\:mainForm\\:simple\\:controllerPopup\\:in1\\:\\:field");
-  var $submitOnPopup = jQueryFrame("#page\\:mainForm\\:simple\\:controllerPopup\\:submitOnPopup1");
-  var $close = jQueryFrame("#page\\:mainForm\\:simple\\:controllerPopup\\:close1");
+  var submitOnPageSelector = "#page\\:mainForm\\:simple\\:submitOnPage1";
+  var $submitOnPage = jQueryFrame(submitOnPageSelector);
+  var inSelector = "#page\\:mainForm\\:simple\\:controllerPopup\\:in1\\:\\:field";
+  var $in = jQueryFrame(inSelector);
+  var submitOnPopupSelector = "#page\\:mainForm\\:simple\\:controllerPopup\\:submitOnPopup1";
+  var $submitOnPopup = jQueryFrame(submitOnPopupSelector);
+  var closeSelector = "#page\\:mainForm\\:simple\\:controllerPopup\\:close1";
+  var $close = jQueryFrame(closeSelector);
 
   $open.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step == 1) {
-      $in = jQueryFrame($in.selector);
-      $submitOnPopup = jQueryFrame($submitOnPopup.selector);
+      $in = jQueryFrame(inSelector);
+      $submitOnPopup = jQueryFrame(submitOnPopupSelector);
 
       assert.equal($in.length, 1);
       $in.val("some text");
@@ -40,9 +45,9 @@ QUnit.test("Simple Popup", function (assert) {
 
       done();
     } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $in = jQueryFrame($in.selector);
-      $submitOnPopup = jQueryFrame($submitOnPopup.selector);
+      $messages = jQueryFrame(messagesSelector);
+      $in = jQueryFrame(inSelector);
+      $submitOnPopup = jQueryFrame(submitOnPopupSelector);
 
       assert.equal($messages.length, 0);
       assert.equal($in.length, 1);
@@ -52,9 +57,9 @@ QUnit.test("Simple Popup", function (assert) {
 
       done();
     } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $in = jQueryFrame($in.selector);
-      $close = jQueryFrame($close.selector);
+      $messages = jQueryFrame(messagesSelector);
+      $in = jQueryFrame(inSelector);
+      $close = jQueryFrame(closeSelector);
 
       assert.equal($messages.length, 1);
       assert.equal($in.length, 1);
@@ -63,15 +68,15 @@ QUnit.test("Simple Popup", function (assert) {
 
       done();
     } else if (step == 4) {
-      $submitOnPage = jQueryFrame($submitOnPage.selector);
-      $in = jQueryFrame($in.selector);
+      $submitOnPage = jQueryFrame(submitOnPageSelector);
+      $in = jQueryFrame(inSelector);
 
       assert.equal($in.length, 0);
       $submitOnPage.click();
 
       done();
     } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
+      $messages = jQueryFrame(messagesSelector);
 
       assert.equal($messages.length, 0);
 
@@ -86,19 +91,24 @@ QUnit.test("Full Server Request", function (assert) {
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var messagesSelector = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(messagesSelector);
   var $open = jQueryFrame("#page\\:mainForm\\:server\\:open2");
-  var $submitOnPage = jQueryFrame("#page\\:mainForm\\:server\\:submitOnPage2");
-  var $in = jQueryFrame("#page\\:mainForm\\:server\\:fullServerRequestPopup\\:in2\\:\\:field");
-  var $submitOnPopup = jQueryFrame("#page\\:mainForm\\:server\\:fullServerRequestPopup\\:submitOnPopup2");
-  var $close = jQueryFrame("#page\\:mainForm\\:server\\:fullServerRequestPopup\\:close2");
+  var submitOnPageSelector = "#page\\:mainForm\\:server\\:submitOnPage2";
+  var $submitOnPage = jQueryFrame(submitOnPageSelector);
+  var inSelector = "#page\\:mainForm\\:server\\:fullServerRequestPopup\\:in2\\:\\:field";
+  var $in = jQueryFrame(inSelector);
+  var submitOnPopupSelector = "#page\\:mainForm\\:server\\:fullServerRequestPopup\\:submitOnPopup2";
+  var $submitOnPopup = jQueryFrame(submitOnPopupSelector);
+  var closeSelector = "#page\\:mainForm\\:server\\:fullServerRequestPopup\\:close2";
+  var $close = jQueryFrame(closeSelector);
 
   $open.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step == 1) {
-      $in = jQueryFrame($in.selector);
-      $submitOnPopup = jQueryFrame($submitOnPopup.selector);
+      $in = jQueryFrame(inSelector);
+      $submitOnPopup = jQueryFrame(submitOnPopupSelector);
 
       assert.equal($in.length, 1);
       $in.val("some text");
@@ -106,9 +116,9 @@ QUnit.test("Full Server Request", function (assert) {
 
       done();
     } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $in = jQueryFrame($in.selector);
-      $submitOnPopup = jQueryFrame($submitOnPopup.selector);
+      $messages = jQueryFrame(messagesSelector);
+      $in = jQueryFrame(inSelector);
+      $submitOnPopup = jQueryFrame(submitOnPopupSelector);
 
       assert.equal($messages.length, 0);
       assert.equal($in.length, 1);
@@ -118,9 +128,9 @@ QUnit.test("Full Server Request", function (assert) {
 
       done();
     } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $in = jQueryFrame($in.selector);
-      $close = jQueryFrame($close.selector);
+      $messages = jQueryFrame(messagesSelector);
+      $in = jQueryFrame(inSelector);
+      $close = jQueryFrame(closeSelector);
 
       assert.equal($messages.length, 1);
       assert.equal($in.length, 1);
@@ -129,15 +139,15 @@ QUnit.test("Full Server Request", function (assert) {
 
       done();
     } else if (step == 4) {
-      $submitOnPage = jQueryFrame($submitOnPage.selector);
-      $in = jQueryFrame($in.selector);
+      $submitOnPage = jQueryFrame(submitOnPageSelector);
+      $in = jQueryFrame(inSelector);
 
       assert.equal($in.length, 0);
       $submitOnPage.click();
 
       done();
     } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
+      $messages = jQueryFrame(messagesSelector);
 
       assert.equal($messages.length, 0);
 
@@ -152,12 +162,18 @@ QUnit.test("Client Sided", function (assert) {
   var done = assert.async(3);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $open = jQueryFrame("#page\\:mainForm\\:client\\:open3");
-  var $submitOnPage = jQueryFrame("#page\\:mainForm\\:client\\:submitOnPage3");
-  var $popupCollapsed = jQueryFrame("#page\\:mainForm\\:client\\:clientPopup\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:client\\:clientPopup\\:in3\\:\\:field");
-  var $submitOnPopup = jQueryFrame("#page\\:mainForm\\:client\\:clientPopup\\:submitOnPopup3");
+  var messagesSelector = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(messagesSelector);
+  var openSelector = "#page\\:mainForm\\:client\\:open3";
+  var $open = jQueryFrame(openSelector);
+  var submitOnPageSelector = "#page\\:mainForm\\:client\\:submitOnPage3";
+  var $submitOnPage = jQueryFrame(submitOnPageSelector);
+  var popupCollapsedSelector = "#page\\:mainForm\\:client\\:clientPopup\\:\\:collapse";
+  var $popupCollapsed = jQueryFrame(popupCollapsedSelector);
+  var inSelector = "#page\\:mainForm\\:client\\:clientPopup\\:in3\\:\\:field";
+  var $in = jQueryFrame(inSelector);
+  var submitOnPopupSelector = "#page\\:mainForm\\:client\\:clientPopup\\:submitOnPopup3";
+  var $submitOnPopup = jQueryFrame(submitOnPopupSelector);
   var $close = jQueryFrame("#page\\:mainForm\\:client\\:clientPopup\\:close3");
 
   $open.click();
@@ -169,13 +185,13 @@ QUnit.test("Client Sided", function (assert) {
   $in.val("some text");
   $submitOnPopup.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step == 1) {
-      $messages = jQueryFrame($messages.selector);
-      $open = jQueryFrame($open.selector);
-      $popupCollapsed = jQueryFrame($popupCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submitOnPopup = jQueryFrame($submitOnPopup.selector);
+      $messages = jQueryFrame(messagesSelector);
+      $open = jQueryFrame(openSelector);
+      $popupCollapsed = jQueryFrame(popupCollapsedSelector);
+      $in = jQueryFrame(inSelector);
+      $submitOnPopup = jQueryFrame(submitOnPopupSelector);
 
       assert.equal($messages.length, 0);
       assert.equal($popupCollapsed.val(), "true");
@@ -186,9 +202,9 @@ QUnit.test("Client Sided", function (assert) {
 
       done();
     } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $submitOnPage = jQueryFrame($submitOnPage.selector);
-      $popupCollapsed = jQueryFrame($popupCollapsed.selector);
+      $messages = jQueryFrame(messagesSelector);
+      $submitOnPage = jQueryFrame(submitOnPageSelector);
+      $popupCollapsed = jQueryFrame(popupCollapsedSelector);
 
       assert.equal($messages.length, 1);
       assert.equal($popupCollapsed.val(), "true");
@@ -196,7 +212,7 @@ QUnit.test("Client Sided", function (assert) {
 
       done();
     } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
+      $messages = jQueryFrame(messagesSelector);
 
       assert.equal($messages.length, 1);
 
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/20-collapsible-panel/collapsible-panel.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/20-collapsible-panel/collapsible-panel.test.js
index 01f650f..41b0f07 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/20-collapsible-panel/collapsible-panel.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/20-collapsible-panel/collapsible-panel.test.js
@@ -20,20 +20,25 @@ QUnit.test("Simple Panel", function (assert) {
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $show = jQueryFrame("#\\page\\:mainForm\\:simple\\:showSimple");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:simple\\:hideSimple");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:simple\\:submitSimple");
-  var $panelCollapsed = jQueryFrame("#page\\:mainForm\\:simple\\:simplePanel\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:simple\\:inSimple\\:\\:field");
+  var h = "#\\page\\:mainForm\\:simple\\:hideSimple";
+  var $hide = jQueryFrame(h);
+  var s = "#\\page\\:mainForm\\:simple\\:submitSimple";
+  var $submit = jQueryFrame(s);
+  var pc = "#page\\:mainForm\\:simple\\:simplePanel\\:\\:collapse";
+  var $panelCollapsed = jQueryFrame(pc);
+  var i = "#page\\:mainForm\\:simple\\:inSimple\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($panelCollapsed.val(), "false");
       assert.equal($in.length, 1);
@@ -42,11 +47,11 @@ QUnit.test("Simple Panel", function (assert) {
 
       step++;
       done();
-    } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+    } else if (step === 2) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "false");
@@ -56,11 +61,11 @@ QUnit.test("Simple Panel", function (assert) {
 
       step++;
       done();
-    } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
+    } else if (step === 3) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
 
       assert.equal($messages.length, 1);
       assert.equal($panelCollapsed.val(), "false");
@@ -69,11 +74,11 @@ QUnit.test("Simple Panel", function (assert) {
 
       step++;
       done();
-    } else if (step == 4) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+    } else if (step === 4) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "true");
@@ -82,10 +87,10 @@ QUnit.test("Simple Panel", function (assert) {
 
       step++;
       done();
-    } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+    } else if (step === 5) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "true");
@@ -101,20 +106,25 @@ QUnit.test("Full Server Request", function (assert) {
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $show = jQueryFrame("#\\page\\:mainForm\\:server\\:showServer");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:server\\:hideServer");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:server\\:submitServer");
-  var $panelCollapsed = jQueryFrame("#page\\:mainForm\\:server\\:serverPanel\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:server\\:inServer\\:\\:field");
+  var h = "#\\page\\:mainForm\\:server\\:hideServer";
+  var $hide = jQueryFrame(h);
+  var s = "#\\page\\:mainForm\\:server\\:submitServer";
+  var $submit = jQueryFrame(s);
+  var pc = "#page\\:mainForm\\:server\\:serverPanel\\:\\:collapse";
+  var $panelCollapsed = jQueryFrame(pc);
+  var i = "#page\\:mainForm\\:server\\:inServer\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($panelCollapsed.val(), "false");
       assert.equal($in.length, 1);
@@ -123,11 +133,11 @@ QUnit.test("Full Server Request", function (assert) {
 
       step++;
       done();
-    } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+    } else if (step === 2) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "false");
@@ -137,11 +147,11 @@ QUnit.test("Full Server Request", function (assert) {
 
       step++;
       done();
-    } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
+    } else if (step === 3) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
 
       assert.equal($messages.length, 1);
       assert.equal($panelCollapsed.val(), "false");
@@ -150,11 +160,11 @@ QUnit.test("Full Server Request", function (assert) {
 
       step++;
       done();
-    } else if (step == 4) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+    } else if (step === 4) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "true");
@@ -163,10 +173,10 @@ QUnit.test("Full Server Request", function (assert) {
 
       step++;
       done();
-    } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+    } else if (step === 5) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "true");
@@ -182,12 +192,17 @@ QUnit.test("Client Sided", function (assert) {
   var done = assert.async(3);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $show = jQueryFrame("#\\page\\:mainForm\\:client\\:showClient");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:client\\:hideClient");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:client\\:submitClient");
-  var $panelCollapsed = jQueryFrame("#page\\:mainForm\\:client\\:clientPanel\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:client\\:inClient\\:\\:field");
+  var h = "#\\page\\:mainForm\\:client\\:hideClient";
+  var $hide = jQueryFrame(h);
+  var s = "#\\page\\:mainForm\\:client\\:submitClient";
+  var $submit = jQueryFrame(s);
+  var pc = "#page\\:mainForm\\:client\\:clientPanel\\:\\:collapse";
+  var $panelCollapsed = jQueryFrame(pc);
+  var i = "#page\\:mainForm\\:client\\:inClient\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
   assert.equal($panelCollapsed.val(), "false");
@@ -195,12 +210,12 @@ QUnit.test("Client Sided", function (assert) {
   $in.val("some text");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "false");
@@ -210,12 +225,12 @@ QUnit.test("Client Sided", function (assert) {
 
       step++;
       done();
-    } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
-      $submit = jQueryFrame($submit.selector);
+    } else if (step === 2) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 1);
       assert.equal($panelCollapsed.val(), "false");
@@ -229,10 +244,10 @@ QUnit.test("Client Sided", function (assert) {
 
       step++;
       done();
-    } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+    } else if (step === 3) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 1);
       assert.equal($panelCollapsed.val(), "false");
@@ -248,25 +263,30 @@ QUnit.test("Ajax", function (assert) {
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
   var $show = jQueryFrame("#\\page\\:mainForm\\:ajax\\:showAjax");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:ajax\\:hideAjax");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:ajax\\:submitAjax");
-  var $panelCollapsed = jQueryFrame("#page\\:mainForm\\:ajax\\:ajaxPanel\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:ajax\\:inAjax\\:\\:field");
+  var h = "#\\page\\:mainForm\\:ajax\\:hideAjax";
+  var $hide = jQueryFrame(h);
+  var s = "#\\page\\:mainForm\\:ajax\\:submitAjax";
+  var $submit = jQueryFrame(s);
+  var pc = "#page\\:mainForm\\:ajax\\:ajaxPanel\\:\\:collapse";
+  var $panelCollapsed = jQueryFrame(pc);
+  var i = "#page\\:mainForm\\:ajax\\:inAjax\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
 
   waitForAjax(function () {
-    $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-    $in = jQueryFrame($in.selector);
-    return step == 1
+    $panelCollapsed = jQueryFrame(pc);
+    $in = jQueryFrame(i);
+    return step === 1
         && $panelCollapsed.val() == "false"
-        && $in.length == 1;
+        && $in.length === 1;
   }, function () {
-    $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-    $in = jQueryFrame($in.selector);
-    $submit = jQueryFrame($submit.selector);
+    $panelCollapsed = jQueryFrame(pc);
+    $in = jQueryFrame(i);
+    $submit = jQueryFrame(s);
 
     assert.equal($panelCollapsed.val(), "false");
     assert.equal($in.length, 1);
@@ -277,12 +297,12 @@ QUnit.test("Ajax", function (assert) {
     done();
   });
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 2) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "false");
@@ -292,11 +312,11 @@ QUnit.test("Ajax", function (assert) {
 
       step++;
       done();
-    } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
+    } else if (step === 3) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
 
       assert.equal($messages.length, 1);
       assert.equal($panelCollapsed.val(), "false");
@@ -307,15 +327,15 @@ QUnit.test("Ajax", function (assert) {
       done();
 
       waitForAjax(function () {
-        $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-        $in = jQueryFrame($in.selector);
-        return step == 4
+        $panelCollapsed = jQueryFrame(pc);
+        $in = jQueryFrame(i);
+        return step === 4
             && $panelCollapsed.val() == "true"
-            && $in.length == 0;
+            && $in.length === 0;
       }, function () {
-        $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-        $in = jQueryFrame($in.selector);
-        $submit = jQueryFrame($submit.selector);
+        $panelCollapsed = jQueryFrame(pc);
+        $in = jQueryFrame(i);
+        $submit = jQueryFrame(s);
 
         assert.equal($panelCollapsed.val(), "true");
         assert.equal($in.length, 0);
@@ -324,10 +344,10 @@ QUnit.test("Ajax", function (assert) {
         step++;
         done();
       });
-    } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
-      $panelCollapsed = jQueryFrame($panelCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+    } else if (step === 5) {
+      $messages = jQueryFrame(m);
+      $panelCollapsed = jQueryFrame(pc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 0);
       assert.equal($panelCollapsed.val(), "true");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/30-collapsible-section/collapsible-section.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/30-collapsible-section/collapsible-section.test.js
index 6b0535f..71cf42a 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/30-collapsible-section/collapsible-section.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/30-concept/53-collapsible/30-collapsible-section/collapsible-section.test.js
@@ -14,26 +14,31 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-
+/*
 QUnit.test("Simple Panel", function (assert) {
   assert.expect(14);
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:simple\\:submitSimple");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
+  var s = "#\\page\\:mainForm\\:simple\\:submitSimple";
+  var $submit = jQueryFrame(s);
   var $show = jQueryFrame("#\\page\\:mainForm\\:simple\\:showSimple");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:simple\\:hideSimple");
-  var $sectionCollapsed = jQueryFrame("#page\\:mainForm\\:simple\\:simpleSection\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:simple\\:inSimple\\:\\:field");
+  var h = "#\\page\\:mainForm\\:simple\\:hideSimple";
+  var $hide = jQueryFrame(h);
+  var sc = "#page\\:mainForm\\:simple\\:simpleSection\\:\\:collapse";
+  var $sectionCollapsed = jQueryFrame(sc);
+  var i = "#page\\:mainForm\\:simple\\:inSimple\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step == 1) {
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($sectionCollapsed.val(), "false");
       assert.equal($in.length, 1);
@@ -43,10 +48,10 @@ QUnit.test("Simple Panel", function (assert) {
       step++;
       done();
     } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "false");
@@ -57,10 +62,10 @@ QUnit.test("Simple Panel", function (assert) {
       step++;
       done();
     } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
 
       assert.equal($messages.length, 1);
       assert.equal($sectionCollapsed.val(), "false");
@@ -70,10 +75,10 @@ QUnit.test("Simple Panel", function (assert) {
       step++;
       done();
     } else if (step == 4) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "true");
@@ -83,9 +88,9 @@ QUnit.test("Simple Panel", function (assert) {
       step++;
       done();
     } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "true");
@@ -101,20 +106,26 @@ QUnit.test("Full Server Request", function (assert) {
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:server\\:submitServer");
+
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
+  var s = "#\\page\\:mainForm\\:server\\:submitServer";
+  var $submit = jQueryFrame(s);
   var $show = jQueryFrame("#\\page\\:mainForm\\:server\\:showServer");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:server\\:hideServer");
-  var $sectionCollapsed = jQueryFrame("#page\\:mainForm\\:server\\:fullRequestSection\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:server\\:inServer\\:\\:field");
+  var h = "#\\page\\:mainForm\\:server\\:hideServer";
+  var $hide = jQueryFrame(h);
+  var sc = "#page\\:mainForm\\:server\\:fullRequestSection\\:\\:collapse";
+  var $sectionCollapsed = jQueryFrame(sc);
+  var i = "#page\\:mainForm\\:server\\:inServer\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step == 1) {
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($sectionCollapsed.val(), "false");
       assert.equal($in.length, 1);
@@ -124,10 +135,10 @@ QUnit.test("Full Server Request", function (assert) {
       step++;
       done();
     } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "false");
@@ -138,10 +149,10 @@ QUnit.test("Full Server Request", function (assert) {
       step++;
       done();
     } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
 
       assert.equal($messages.length, 1);
       assert.equal($sectionCollapsed.val(), "false");
@@ -151,10 +162,10 @@ QUnit.test("Full Server Request", function (assert) {
       step++;
       done();
     } else if (step == 4) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "true");
@@ -164,9 +175,9 @@ QUnit.test("Full Server Request", function (assert) {
       step++;
       done();
     } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "true");
@@ -182,12 +193,18 @@ QUnit.test("Client Sided", function (assert) {
   var done = assert.async(3);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:client\\:submitClient");
-  var $show = jQueryFrame("#\\page\\:mainForm\\:client\\:showClient");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:client\\:hideClient");
-  var $sectionCollapsed = jQueryFrame("#page\\:mainForm\\:client\\:clientSection\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:client\\:inClient\\:\\:field");
+
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m);
+  var s = "#\\page\\:mainForm\\:client\\:submitClient";
+  var $submit = jQueryFrame(s);
+  var $show = jQueryFrame("#\\ page\\:mainForm\\:client\\:showClient");
+  var h = "#\\page\\:mainForm\\:client\\:hideClient";
+  var $hide = jQueryFrame(h);
+  var sc = "#page\\:mainForm\\:client\\:clientSection\\:\\:collapse";
+  var $sectionCollapsed = jQueryFrame(sc);
+  var i = "#page\\:mainForm\\:client\\:inClient\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
   assert.equal($sectionCollapsed.val(), "false");
@@ -195,12 +212,12 @@ QUnit.test("Client Sided", function (assert) {
   $in.val("some text");
   $submit.click();
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step == 1) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "false");
@@ -211,11 +228,11 @@ QUnit.test("Client Sided", function (assert) {
       step++;
       done();
     } else if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
-      $submit = jQueryFrame($submit.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 1);
       assert.equal($sectionCollapsed.val(), "false");
@@ -230,9 +247,9 @@ QUnit.test("Client Sided", function (assert) {
       step++;
       done();
     } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 1);
       assert.equal($sectionCollapsed.val(), "false");
@@ -242,31 +259,36 @@ QUnit.test("Client Sided", function (assert) {
     }
   });
 });
-
+*/
 QUnit.test("Ajax", function (assert) {
   assert.expect(13);
   var done = assert.async(5);
   var step = 1;
 
-  var $messages = jQueryFrame("#page\\:messages .tobago-messages");
-  var $submit = jQueryFrame("#\\page\\:mainForm\\:ajax\\:submitAjax");
-  var $show = jQueryFrame("#\\page\\:mainForm\\:ajax\\:showAjax");
-  var $hide = jQueryFrame("#\\page\\:mainForm\\:ajax\\:hideAjax");
-  var $sectionCollapsed = jQueryFrame("#page\\:mainForm\\:ajax\\:ajaxSection\\:\\:collapse");
-  var $in = jQueryFrame("#page\\:mainForm\\:ajax\\:inAjax\\:\\:field");
+  var m = "#page\\:messages .tobago-messages";
+  var $messages = jQueryFrame(m)  ;
+  var s = "#\\page\\:mainForm\\:ajax\\:submitAjax";
+  var $submit = jQueryFrame(s);
+  var $show = jQueryFrame("#\\ page\\:mainForm\\:ajax\\:showAjax");
+  var h = "#\\page\\:mainForm\\:ajax\\:hideAjax";
+  var $hide = jQueryFrame(h);
+  var sc = "#page\\:mainForm\\:ajax\\:ajaxSection\\:\\:collapse";
+  var $sectionCollapsed = jQueryFrame(sc);
+  var i = "#page\\:mainForm\\:ajax\\:inAjax\\:\\:field";
+  var $in = jQueryFrame(i);
 
   $show.click();
 
   waitForAjax(function () {
-    $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-    $in = jQueryFrame($in.selector);
+    $sectionCollapsed = jQueryFrame(sc);
+    $in = jQueryFrame(i);
     return step == 1
         && $sectionCollapsed.val() == "false"
         && $in.length == 1;
   }, function () {
-    $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-    $in = jQueryFrame($in.selector);
-    $submit = jQueryFrame($submit.selector);
+    $sectionCollapsed = jQueryFrame(sc);
+    $in = jQueryFrame(i);
+    $submit = jQueryFrame(s);
 
     assert.equal($sectionCollapsed.val(), "false");
     assert.equal($in.length, 1);
@@ -277,12 +299,12 @@ QUnit.test("Ajax", function (assert) {
     done();
   });
 
-  jQuery("#page\\:testframe").load(function () {
+  jQuery("#page\\:testframe").on("load", function () {
     if (step == 2) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $submit = jQueryFrame($submit.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $submit = jQueryFrame(s);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "false");
@@ -293,10 +315,10 @@ QUnit.test("Ajax", function (assert) {
       step++;
       done();
     } else if (step == 3) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
-      $hide = jQueryFrame($hide.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
+      $hide = jQueryFrame(h);
 
       assert.equal($messages.length, 1);
       assert.equal($sectionCollapsed.val(), "false");
@@ -307,15 +329,15 @@ QUnit.test("Ajax", function (assert) {
       done();
 
       waitForAjax(function () {
-        $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-        $in = jQueryFrame($in.selector);
+        $sectionCollapsed = jQueryFrame(sc);
+        $in = jQueryFrame(i);
         return step == 4
             && $sectionCollapsed.val() == "true"
             && $in.length == 0;
       }, function () {
-        $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-        $in = jQueryFrame($in.selector);
-        $submit = jQueryFrame($submit.selector);
+        $sectionCollapsed = jQueryFrame(sc);
+        $in = jQueryFrame(i);
+        $submit = jQueryFrame(s);
 
         assert.equal($sectionCollapsed.val(), "true");
         assert.equal($in.length, 0);
@@ -325,9 +347,9 @@ QUnit.test("Ajax", function (assert) {
         done();
       });
     } else if (step == 5) {
-      $messages = jQueryFrame($messages.selector);
-      $sectionCollapsed = jQueryFrame($sectionCollapsed.selector);
-      $in = jQueryFrame($in.selector);
+      $messages = jQueryFrame(m);
+      $sectionCollapsed = jQueryFrame(sc);
+      $in = jQueryFrame(i);
 
       assert.equal($messages.length, 0);
       assert.equal($sectionCollapsed.val(), "true");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/35-deprecated/15-suggest-method/suggest-method.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/35-deprecated/15-suggest-method/suggest-method.test.js
index 7608af9..9d4b327 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/35-deprecated/15-suggest-method/suggest-method.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/35-deprecated/15-suggest-method/suggest-method.test.js
@@ -23,15 +23,16 @@ QUnit.test("Deprecated: 'Chile'", function (assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:deprecated\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:deprecated");
+  var s = "#page\\:mainForm\\:deprecated";
+  var $suggestions = getSuggestions(s);
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function () {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestions(s);
     return $suggestions.length == expectedLength;
   }, function () {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestions(s);
 
     assert.equal($suggestions.length, expectedLength);
     for (i = 0; i < expectedLength; i++) {
@@ -50,15 +51,16 @@ QUnit.test("Replacement: 'Chile'", function (assert) {
   var done = assert.async();
 
   var $in = jQueryFrame("#page\\:mainForm\\:replacement\\:\\:field");
-  var $suggestions = getSuggestions("#page\\:mainForm\\:replacement");
+  var s = "#page\\:mainForm\\:replacement";
+  var $suggestions = getSuggestions(s);
 
   $in.val(inputString).trigger('input');
 
   waitForAjax(function () {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestions(s);
     return $suggestions.length == expectedLength;
   }, function () {
-    $suggestions = jQueryFrame($suggestions.selector);
+    $suggestions = getSuggestions(s);
 
     assert.equal($suggestions.length, expectedLength);
     for (i = 0; i < expectedLength; i++) {
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/4000-button+link/button+link.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/4000-button+link/button+link.test.js
index 3296d71..2b04b1e 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/4000-button+link/button+link.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/4000-button+link/button+link.test.js
@@ -19,51 +19,45 @@ QUnit.test("Standard Action Button", function(assert) {
   assert.expect(2);
   var done = assert.async(2);
 
-  var $command = jQueryFrame("#page\\:mainForm\\:standardButtonAction");
-  var $destinationSection = jQueryFrame("#page\\:actionSection");
-  testStandardCommands($command, $destinationSection, assert, done);
+  testStandardCommands("#page\\:mainForm\\:standardButtonAction", "#page\\:actionSection", assert, done);
 });
 
 QUnit.test("Standard Link Button", function(assert) {
   assert.expect(2);
   var done = assert.async(2);
 
-  var $command = jQueryFrame("#page\\:mainForm\\:standardButtonLink");
-  var $destinationSection = jQueryFrame("#page\\:linkSection");
-  testStandardCommands($command, $destinationSection, assert, done);
+  testStandardCommands("#page\\:mainForm\\:standardButtonLink", "#page\\:linkSection", assert, done);
 });
 
 QUnit.test("Standard Action Link", function(assert) {
   assert.expect(2);
   var done = assert.async(2);
 
-  var $command = jQueryFrame("#page\\:mainForm\\:standardLinkAction");
-  var $destinationSection = jQueryFrame("#page\\:actionSection");
-  testStandardCommands($command, $destinationSection, assert, done);
+  testStandardCommands("#page\\:mainForm\\:standardLinkAction", "#page\\:actionSection", assert, done);
 });
 
 QUnit.test("Standard Link Link", function(assert) {
   assert.expect(2);
   var done = assert.async(2);
 
-  var $command = jQueryFrame("#page\\:mainForm\\:standardLinkLink");
-  var $destinationSection = jQueryFrame("#page\\:linkSection");
-  testStandardCommands($command, $destinationSection, assert, done);
+  testStandardCommands("#page\\:mainForm\\:standardLinkLink", "#page\\:linkSection", assert, done);
 });
 
-function testStandardCommands($command, $destinationSection, assert, done) {
+function testStandardCommands(commandSelector, destinationSectionSelector, assert, done) {
   var step = 1;
+  var $command = jQueryFrame(commandSelector);
+  var $destinationSection = jQueryFrame(destinationSectionSelector);
   $command[0].click();
 
-  jQuery("#page\\:testframe").load(function() {
+  jQuery("#page\\:testframe").on("load", function() {
     if (step == 1) {
-      $destinationSection = jQueryFrame($destinationSection.selector);
+      $destinationSection = jQueryFrame(destinationSectionSelector);
       assert.equal($destinationSection.length, 1);
 
       var $back = jQueryFrame("#page\\:back");
       $back[0].click();
     } else if (step == 2) {
-      $command = jQueryFrame($command.selector);
+      $command = jQueryFrame(commandSelector);
       assert.equal($command.length, 1);
     }
     step++;
@@ -93,21 +87,19 @@ QUnit.test("Target Action Link", function(assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $command = jQueryFrame("#page\\:mainForm\\:targetLinkAction");
-  var $destinationSection = jQueryTargetFrame("#page\\:actionSection");
-  testTargetCommands($command, $destinationSection, assert, done);
+  testTargetCommands("#page\\:mainForm\\:targetLinkAction", "#page\\:actionSection", assert, done);
 });
 
 QUnit.test("Target Link Link", function(assert) {
   assert.expect(1);
   var done = assert.async();
 
-  var $command = jQueryFrame("#page\\:mainForm\\:targetLinkLink");
-  var $destinationSection = jQueryTargetFrame("#page\\:linkSection");
-  testTargetCommands($command, $destinationSection, assert, done);
+  testTargetCommands("#page\\:mainForm\\:targetLinkLink", "#page\\:linkSection", assert, done);
 });
 
-function testTargetCommands($command, $destinationSection, assert, done) {
+function testTargetCommands(commandSelector, destinationSectionSelector, assert, done) {
+  var $command = jQueryFrame(commandSelector);
+  var $destinationSection = jQueryFrame(destinationSectionSelector);
   $command[0].click();
 
   /*
@@ -115,10 +107,10 @@ function testTargetCommands($command, $destinationSection, assert, done) {
    * so the waitForAjax() method is used instead.
    */
   waitForAjax(function() {
-    $destinationSection = jQueryTargetFrame($destinationSection.selector);
-    return $destinationSection.length == 1;
+    $destinationSection = jQueryTargetFrame(destinationSectionSelector);
+    return $destinationSection.length === 1;
   }, function() {
-    $destinationSection = jQueryTargetFrame($destinationSection.selector);
+    $destinationSection = jQueryTargetFrame(destinationSectionSelector);
     assert.equal($destinationSection.length, 1);
     done();
   });
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/20-ajax-execute/ajax-execute.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/20-ajax-execute/ajax-execute.test.js
index 1675dc0..21875d3 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/20-ajax-execute/ajax-execute.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/20-ajax-execute/ajax-execute.test.js
@@ -20,13 +20,20 @@ QUnit.test("ajax excecute", function (assert) {
   var done = assert.async(3);
   var step = 1;
 
-  var $in1 = jQueryFrame("#page\\:mainForm\\:in1\\:\\:field");
-  var $in2 = jQueryFrame("#page\\:mainForm\\:in2\\:\\:field");
-  var $in3 = jQueryFrame("#page\\:mainForm\\:in3\\:\\:field");
-  var $in4 = jQueryFrame("#page\\:mainForm\\:in4\\:\\:field");
-  var $clearButton = jQueryFrame("#page\\:mainForm\\:clear");
-  var $submitButton = jQueryFrame("#page\\:mainForm\\:submit");
-  var $reloadButton = jQueryFrame("#page\\:mainForm\\:reload");
+  var in1Selector = "#page\\:mainForm\\:in1\\:\\:field";
+  var in2Selector = "#page\\:mainForm\\:in2\\:\\:field";
+  var in3Selector = "#page\\:mainForm\\:in3\\:\\:field";
+  var in4Selector = "#page\\:mainForm\\:in4\\:\\:field";
+  var clearButtonSelector = "#page\\:mainForm\\:clear";
+  var submitButtonSelector = "#page\\:mainForm\\:submit";
+  var reloadButtonSelector = "#page\\:mainForm\\:reload";
+  var $in1 = jQueryFrame(in1Selector);
+  var $in2 = jQueryFrame(in2Selector);
+  var $in3 = jQueryFrame(in3Selector);
+  var $in4 = jQueryFrame(in4Selector);
+  var $clearButton = jQueryFrame(clearButtonSelector);
+  var $submitButton = jQueryFrame(submitButtonSelector);
+  var $reloadButton = jQueryFrame(reloadButtonSelector);
 
   $in1.val("a");
   $in2.val("b");
@@ -34,13 +41,13 @@ QUnit.test("ajax excecute", function (assert) {
   $in4.val("d");
   $clearButton.click();
 
-  jQuery("#page\\:testframe").load(function () {
-    if (step == 1) {
-      $in1 = jQueryFrame($in1.selector);
-      $in2 = jQueryFrame($in2.selector);
-      $in3 = jQueryFrame($in3.selector);
-      $in4 = jQueryFrame($in4.selector);
-      $submitButton = jQueryFrame($submitButton.selector);
+  jQuery("#page\\:testframe").on("load", function () {
+    if (step === 1) {
+      $in1 = jQueryFrame(in1Selector);
+      $in2 = jQueryFrame(in2Selector);
+      $in3 = jQueryFrame(in3Selector);
+      $in4 = jQueryFrame(in4Selector);
+      $submitButton = jQueryFrame(submitButtonSelector);
 
       assert.equal($in1.val(), "");
       assert.equal($in2.val(), "");
@@ -58,21 +65,21 @@ QUnit.test("ajax excecute", function (assert) {
       done();
 
       waitForAjax(function () {
-        $in1 = jQueryFrame($in1.selector);
-        $in2 = jQueryFrame($in2.selector);
-        $in3 = jQueryFrame($in3.selector);
-        $in4 = jQueryFrame($in4.selector);
-        return step == 2
-            && $in1.val() == "a"
-            && $in2.val() == "b"
-            && $in3.val() == "c"
-            && $in4.val() == "";
+        $in1 = jQueryFrame(in1Selector);
+        $in2 = jQueryFrame(in2Selector);
+        $in3 = jQueryFrame(in3Selector);
+        $in4 = jQueryFrame(in4Selector);
+        return step === 2
+            && $in1.val() === "a"
+            && $in2.val() === "b"
+            && $in3.val() === "c"
+            && $in4.val() === "";
       }, function () {
-        $in1 = jQueryFrame($in1.selector);
-        $in2 = jQueryFrame($in2.selector);
-        $in3 = jQueryFrame($in3.selector);
-        $in4 = jQueryFrame($in4.selector);
-        $reloadButton = jQueryFrame($reloadButton.selector);
+        $in1 = jQueryFrame(in1Selector);
+        $in2 = jQueryFrame(in2Selector);
+        $in3 = jQueryFrame(in3Selector);
+        $in4 = jQueryFrame(in4Selector);
+        $reloadButton = jQueryFrame(reloadButtonSelector);
 
         assert.equal($in1.val(), "a");
         assert.equal($in2.val(), "b");
@@ -84,11 +91,11 @@ QUnit.test("ajax excecute", function (assert) {
         step++;
         done();
       });
-    } else if (step == 3) {
-      $in1 = jQueryFrame($in1.selector);
-      $in2 = jQueryFrame($in2.selector);
-      $in3 = jQueryFrame($in3.selector);
-      $in4 = jQueryFrame($in4.selector);
+    } else if (step === 3) {
+      $in1 = jQueryFrame(in1Selector);
+      $in2 = jQueryFrame(in2Selector);
+      $in3 = jQueryFrame(in3Selector);
+      $in4 = jQueryFrame(in4Selector);
 
       assert.equal($in1.val(), "a");
       assert.equal($in2.val(), "");
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/30-ajax-special-character/ajax-special-character.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/30-ajax-special-character/ajax-special-character.test.js
index 4ab8143..ce7c139 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/30-ajax-special-character/ajax-special-character.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/50000-java/30-ajax-special-character/ajax-special-character.test.js
@@ -19,9 +19,12 @@ QUnit.test("ajax excecute", function (assert) {
   assert.expect(3);
   var done = assert.async();
 
-  var $timestamp = jQueryFrame("#page\\:mainForm\\:timestamp span");
-  var $text = jQueryFrame("#page\\:mainForm\\:outText span");
-  var $tip = jQueryFrame("#page\\:mainForm\\:outTip span");
+  var ts = "#page\\:mainForm\\:timestamp span";
+  var $timestamp = jQueryFrame(ts);
+  var tx = "#page\\:mainForm\\:outText span";
+  var $text = jQueryFrame(tx);
+  var tp = "#page\\:mainForm\\:outTip span";
+  var $tip = jQueryFrame(tp);
   var $button = jQueryFrame("#page\\:mainForm\\:ajaxButton");
 
   var timestampValue = $timestamp.text();
@@ -31,17 +34,17 @@ QUnit.test("ajax excecute", function (assert) {
   $button.click();
 
   waitForAjax(function () {
-    $timestamp = jQueryFrame($timestamp.selector);
-    $text = jQueryFrame($text.selector);
-    $tip = jQueryFrame($tip.selector);
+    $timestamp = jQueryFrame(ts);
+    $text = jQueryFrame(tx);
+    $tip = jQueryFrame(tp);
 
     return $timestamp.text() !== timestampValue
         && $text.text() === textValue
         && $tip.attr('title') === tipValue;
   }, function () {
-    $timestamp = jQueryFrame($timestamp.selector);
-    $text = jQueryFrame($text.selector);
-    $tip = jQueryFrame($tip.selector);
+    $timestamp = jQueryFrame(ts);
+    $text = jQueryFrame(tx);
+    $tip = jQueryFrame(tp);
 
     assert.notEqual($timestamp.text(), timestampValue);
     assert.equal($text.text(), textValue);
diff --git a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/6000-event/event.test.js b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/6000-event/event.test.js
index 7ea7120..6915389 100644
--- a/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/6000-event/event.test.js
+++ b/tobago-example/tobago-example-demo/src/main/webapp/content/40-test/6000-event/event.test.js
@@ -178,7 +178,7 @@ function testEvent(assert, componentName, componentFunc, event,
     activateComponent(componentName);
     var step = 1;
 
-    jQuery("#page\\:testframe").load(function() {
+    jQuery("#page\\:testframe").on("load", function() {
       if (step == 1) {
         oldActionCount = getActionCount();
         oldActionListenerCount = getActionListenerCount();
@@ -206,7 +206,7 @@ function testEvent(assert, componentName, componentFunc, event,
 
     componentFunc().trigger(event);
 
-    jQuery("#page\\:testframe").load(function() {
+    jQuery("#page\\:testframe").on("load", function() {
       validateEvent(assert, oldActionCount, oldActionListenerCount, oldAjaxListenerCount, oldValueChangeListenerCount,
           oldTimestamp, oldPlanet, incAction, incActionListener, incAjaxListener, incValueChangeListener, changePlanet);
 
@@ -256,7 +256,7 @@ function testAjax(assert, componentName, componentFunc, event,
     activateComponent(componentName);
     var step = 1;
 
-    jQuery("#page\\:testframe").load(function() {
+    jQuery("#page\\:testframe").on("load", function() {
       if (step == 1) {
         oldActionCount = getActionCount();
         oldActionListenerCount = getActionListenerCount();
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 2dda3ed..316796f 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
@@ -16,7 +16,10 @@
  */
 
 function jQueryFrame(expression) {
-  return document.getElementById("page:testframe").contentWindow.jQuery(expression);
+  var elementById = document.getElementById("page:testframe");
+  var contentWindow = elementById.contentWindow;
+  console.log("expression=" + expression);
+  return contentWindow.jQuery(expression);
 }
 
 /**
diff --git a/tobago-example/tobago-example-test/src/main/webapp/test/version/version.js b/tobago-example/tobago-example-test/src/main/webapp/test/version/version.js
index ca2afbc..7c1dd7c 100644
--- a/tobago-example/tobago-example-test/src/main/webapp/test/version/version.js
+++ b/tobago-example/tobago-example-test/src/main/webapp/test/version/version.js
@@ -20,7 +20,7 @@ TestVersion = {};
 TestVersion.init = function () {
 
   var checked = jQuery("input[checked]");
-  if (checked.size() != 2) {
+  if (checked.length !== 2) {
     TobagoAssert.fail("2 field must be checked", null, 2, checked);
   }
 
@@ -29,14 +29,14 @@ TestVersion.init = function () {
   var version = checked.eq(0).next().html().toLowerCase();
   var packageVersion = "version " + textList.eq(0).val().toLowerCase();
 
-  if (packageVersion.indexOf(version) == -1) {
+  if (packageVersion.indexOf(version) === -1) {
     TobagoAssert.fail("Version number", null, version, packageVersion);
   }
 
   var impl = checked.eq(1).next().html().toLowerCase();
   var packageImpl = textList.eq(1).val().toLowerCase();
 
-  if (packageImpl.indexOf(impl) == -1) {
+  if (packageImpl.indexOf(impl) === -1) {
     TobagoAssert.fail("Implementation", null, impl, packageImpl);
   }
 };
diff --git a/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/resources/tobago/standard/script/tobago.js b/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/resources/tobago/standard/script/tobago.js
index 6f6ee4f..160637b 100644
--- a/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/resources/tobago/standard/script/tobago.js
+++ b/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/resources/tobago/standard/script/tobago.js
@@ -623,7 +623,7 @@ var Tobago = {
     if (self == top) {
       jQuery(".tobago-page-preventFrameAttacks").removeClass("tobago-page-preventFrameAttacks");
     } else {
-      if (jQuery(".tobago-page-preventFrameAttacks").size() > 0) { // preventFrameAttacks is true
+      if (jQuery(".tobago-page-preventFrameAttacks").length > 0) { // preventFrameAttacks is true
         var page = Tobago.findPage();
         page.attr("title", "This application can't be used embedded inside an other site " +
         "(configuration: prevent-frame-attacks=true)!");


Mime
View raw message