From db4b892720304d42917bf6e9fc7ebb6ea2261d5b Mon Sep 17 00:00:00 2001 From: Tony Atkins Date: Thu, 12 Oct 2017 14:00:32 +0200 Subject: [PATCH] GPII-2515: Fixed calls to `ok` method to use `assertTrue`. --- .../nodegsettings/nodegsettings_tests.js | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/gpii/node_modules/gsettingsBridge/nodegsettings/nodegsettings_tests.js b/gpii/node_modules/gsettingsBridge/nodegsettings/nodegsettings_tests.js index 7603294..4046dd5 100644 --- a/gpii/node_modules/gsettingsBridge/nodegsettings/nodegsettings_tests.js +++ b/gpii/node_modules/gsettingsBridge/nodegsettings/nodegsettings_tests.js @@ -31,13 +31,13 @@ jqUnit.test("Test getting and setting boolean values...", function () { // assert.deepEqual(typeof(original), "boolean", "We got a boolean as expected"); var ret = gsettings.set_gsetting(keyScreenmag, "show-cross-hairs", true); - jqUnit.ok("Setting the value should succeed...", ret); + jqUnit.assertTrue("Setting the value should succeed...", ret); var actual = gsettings.get_gsetting(keyScreenmag, "show-cross-hairs"); jqUnit.assertEquals("We can set boolean values...", true, actual); ret = gsettings.set_gsetting(keyScreenmag, "show-cross-hairs", original); - jqUnit.ok("We can set the value back to its previous value...", ret); + jqUnit.assertTrue("We can set the value back to its previous value...", ret); // TODO: We need to set up an event for these assertions, they run too fast, // and get the old value from gsettings before it's propagated. @@ -55,43 +55,43 @@ jqUnit.test("Test getting and setting boolean values...", function () { jqUnit.test("Test getting and setting decimal values...", function () { var original = gsettings.get_gsetting(keyScreenmag, "mag-factor"); var ret = gsettings.set_gsetting(keyScreenmag, "mag-factor", 3.0); - jqUnit.ok("Setting the value should succeed...", ret); + jqUnit.assertTrue("Setting the value should succeed...", ret); var actual = gsettings.get_gsetting(keyScreenmag, "mag-factor"); jqUnit.assertEquals("We can set decimal values", 3.0, actual); var ret2 = gsettings.set_gsetting(keyScreenmag, "mag-factor", 5.3); - jqUnit.ok("Resetting the value should succeed...", ret2); + jqUnit.assertTrue("Resetting the value should succeed...", ret2); actual = gsettings.get_gsetting(keyScreenmag, "mag-factor"); jqUnit.assertEquals("We can reset decimal values", 5.3, actual); var ret3 = gsettings.set_gsetting(keyScreenmag, "mag-factor", original); - jqUnit.ok("Setting the value should succeed...", ret3); + jqUnit.assertTrue("Setting the value should succeed...", ret3); }); jqUnit.test("Test getting and setting string values...", function () { var original = gsettings.get_gsetting(keyScreenmag, "screen-position"); var ret = gsettings.set_gsetting(keyScreenmag, "screen-position", "left-half"); - jqUnit.ok("Setting the value should succeed...", ret); + jqUnit.assertTrue("Setting the value should succeed...", ret); var actual = gsettings.get_gsetting(keyScreenmag, "screen-position"); jqUnit.assertEquals("We can set string values", "left-half", actual); var ret2 = gsettings.set_gsetting(keyScreenmag, "screen-position", original); - jqUnit.ok("Setting the value should succeed...", ret2); + jqUnit.assertTrue("Setting the value should succeed...", ret2); }); jqUnit.test("Test getting and setting integer values...", function () { var original = gsettings.get_gsetting(keyScreenmag, "cross-hairs-thickness"); var ret = gsettings.set_gsetting(keyScreenmag, "cross-hairs-thickness", 7); - jqUnit.ok("Setting the value should succeed...", ret); + jqUnit.assertTrue("Setting the value should succeed...", ret); var actual = gsettings.get_gsetting(keyScreenmag, "cross-hairs-thickness"); jqUnit.assertEquals("We can set integer values", 7, actual); var ret2 = gsettings.set_gsetting(keyScreenmag, "cross-hairs-thickness", original); - jqUnit.ok("Setting the value should succeed...", ret2); + jqUnit.assertTrue("Setting the value should succeed...", ret2); }); jqUnit.test("Test listing keys...", function () { var keys = gsettings.get_gsetting_keys(keyScreenmag); - jqUnit.ok("Requesting a list of keys should return the correct type of variable...", Array.isArray(keys)); + jqUnit.assertTrue("Requesting a list of keys should return the correct type of variable...", Array.isArray(keys)); for (var i = 0; i < keys.length; i++) { jqUnit.assertEquals("Each value in the list should be a string...", "string", typeof (keys[i]));