From 77f8a9e77a1c8c53afbf78b1914ee5c8923fe704 Mon Sep 17 00:00:00 2001 From: spnraju Date: Sat, 10 Nov 2018 11:56:24 +0530 Subject: [PATCH 1/7] add links to vscode market place --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index ea9bc16..559cac4 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,6 @@ # vscode-nightwatchjs-snippets NightwatchJS code snippets for Visual Studio Code + +[![Version](https://vsmarketplacebadge.apphb.com/version/xabikos.JavaScriptSnippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) +[![Installs](https://vsmarketplacebadge.apphb.com/installs/xabikos.JavaScriptSnippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) +[![Ratings](https://vsmarketplacebadge.apphb.com/rating/xabikos.JavaScriptSnippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) From bc94cbef0a408517b7ee6a1457d6d31cbe9c3fbc Mon Sep 17 00:00:00 2001 From: spnraju Date: Sat, 10 Nov 2018 12:19:39 +0530 Subject: [PATCH 2/7] update vs market place urls in readme --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 559cac4..583a372 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # vscode-nightwatchjs-snippets NightwatchJS code snippets for Visual Studio Code -[![Version](https://vsmarketplacebadge.apphb.com/version/xabikos.JavaScriptSnippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) -[![Installs](https://vsmarketplacebadge.apphb.com/installs/xabikos.JavaScriptSnippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) -[![Ratings](https://vsmarketplacebadge.apphb.com/rating/xabikos.JavaScriptSnippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) +[![Version](https://vsmarketplacebadge.apphb.com/version/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) +[![Installs](https://vsmarketplacebadge.apphb.com/installs/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) +[![Ratings](https://vsmarketplacebadge.apphb.com/rating/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) From 792048a7ac6c6e98b11e164867d18f725681a9d0 Mon Sep 17 00:00:00 2001 From: spnraju Date: Sun, 11 Nov 2018 15:02:47 +0530 Subject: [PATCH 3/7] update readme file --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index 583a372..201c994 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ -# vscode-nightwatchjs-snippets -NightwatchJS code snippets for Visual Studio Code +# NightwatchJS code snippets for Visual Studio Code [![Version](https://vsmarketplacebadge.apphb.com/version/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) [![Installs](https://vsmarketplacebadge.apphb.com/installs/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) From e53ee45c6abc877be627b19596851e80ace2aa9a Mon Sep 17 00:00:00 2001 From: spnraju Date: Sun, 11 Nov 2018 15:05:49 +0530 Subject: [PATCH 4/7] add client commands --- snippets/nightwatchsnippets.json | 125 ++++++++++++++++++++++++++++--- 1 file changed, 114 insertions(+), 11 deletions(-) diff --git a/snippets/nightwatchsnippets.json b/snippets/nightwatchsnippets.json index a15bbdf..6bee25b 100644 --- a/snippets/nightwatchsnippets.json +++ b/snippets/nightwatchsnippets.json @@ -1,14 +1,117 @@ { - "clickWithCallback": { - "prefix": "ckc", - "body": "click(${1:selector}, ${2:callback})$3", - "description": "click(selector,callback)" - }, - - "click": { - "prefix": "ck", - "body": "click(${1:selector})$2", - "description": "click(selector)" + "end": { + "prefix": "end", + "body": "end(${0:optionalCallback})", + "description": "end" + }, + "pause": { + "prefix": "pau", + "body": "pause(${0:1000ms}, ${1:optionalCallback})", + "description": "pause" + }, + "perform": { + "prefix": "per", + "body": "perform(${0:optionalCallback})", + "description": "perform" + }, + "useCss": { + "prefix": "use", + "body": "useCss(${0:optionalCallback})", + "description": "useCss" + }, + "useXpath": { + "prefix": "use", + "body": "useXpath(${0:optionalCallback})", + "description": "useXpath" + }, + "switchWindow": { + "prefix": "swi", + "body": "switchWindow(${0:handleOrName}, ${1:optionalCallback})", + "description": "switchWindow" + }, + "resizeWindow": { + "prefix": "res", + "body": "resizeWindow(${0:width}, ${1:height}, ${2:optionalCallback})", + "description": "resizeWindow" + }, + "setWindowPosition": { + "prefix": "set", + "body": "setWindowPosition(${0:offsetX}, ${1:offsetY}, ${2:optionalCallback})", + "description": "setWindowPosition" + }, + "maximizeWindow": { + "prefix": "max", + "body": "maximizeWindow(${0:optionalCallback})", + "description": "maximizeWindow" + }, + "saveScreenshot": { + "prefix": "save", + "body": "saveScreenshot(${0:fileName}, ${1:optionalCallback})", + "description": "saveScreenshot" + }, + "getTitle": { + "prefix": "get", + "body": "getTitle(${0:callback})", + "description": "getTitle" + }, + "closeWindow": { + "prefix": "clo", + "body": "closeWindow(${0:optionalCallback})", + "description": "closeWindow" + }, + "init": { + "prefix": "in", + "body": "init(${0:URL}, ${1:optionalCallback})", + "description": "init" + }, + "urlHash": { + "prefix": "url", + "body": "urlHash(${0:hash}, ${1:optionalCallback})", + "description": "urlHash" + }, + "getCookies": { + "prefix": "get", + "body": "getCookies(${0:callback})", + "description": "getCookies" + }, + "getCookie": { + "prefix": "get", + "body": "getCookie(${0:cookieName}, ${1:callback})", + "description": "getCookie" + }, + "setCookie": { + "prefix": "set", + "body": "setCookie(${0:cookieObject}, ${1:optionalCallback})", + "description": "setCookie" + }, + "deleteCookie": { + "prefix": "del", + "body": "deleteCookie(${0:cookieName}, ${1:callback})", + "description": "deleteCookie" + }, + "deleteCookies": { + "prefix": "del", + "body": "deleteCookies(${0:optionalCallback})", + "description": "deleteCookies" + }, + "injectScript": { + "prefix": "inj", + "body": "injectScript(${0:scriptUrl}, ${1:id}, ${2:optionalCallback})", + "description": "injectScript" + }, + "getLogTypes": { + "prefix": "get", + "body": "getLogTypes(${0:callback})", + "description": "getLogTypes" + }, + "getLog": { + "prefix": "get", + "body": "getLog(${0:typeString}, ${1:callback})", + "description": "getLog" + }, + "isLogAvailable": { + "prefix": "is", + "body": "isLogAvailable(${0:typeString}, ${1:callback})", + "description": "isLogAvailable" } - } \ No newline at end of file From 85c1d5a6e9fa19e256e70be9b8a18c033550e932 Mon Sep 17 00:00:00 2001 From: spnraju Date: Sun, 11 Nov 2018 15:56:27 +0530 Subject: [PATCH 5/7] add more client commands and assertions --- snippets/nightwatchsnippets.json | 400 ++++++++++++++++++++++--------- 1 file changed, 285 insertions(+), 115 deletions(-) diff --git a/snippets/nightwatchsnippets.json b/snippets/nightwatchsnippets.json index 6bee25b..45d9c1b 100644 --- a/snippets/nightwatchsnippets.json +++ b/snippets/nightwatchsnippets.json @@ -1,117 +1,287 @@ { - "end": { - "prefix": "end", - "body": "end(${0:optionalCallback})", - "description": "end" - }, - "pause": { - "prefix": "pau", - "body": "pause(${0:1000ms}, ${1:optionalCallback})", - "description": "pause" - }, - "perform": { - "prefix": "per", - "body": "perform(${0:optionalCallback})", - "description": "perform" - }, - "useCss": { - "prefix": "use", - "body": "useCss(${0:optionalCallback})", - "description": "useCss" - }, - "useXpath": { - "prefix": "use", - "body": "useXpath(${0:optionalCallback})", - "description": "useXpath" - }, - "switchWindow": { - "prefix": "swi", - "body": "switchWindow(${0:handleOrName}, ${1:optionalCallback})", - "description": "switchWindow" - }, - "resizeWindow": { - "prefix": "res", - "body": "resizeWindow(${0:width}, ${1:height}, ${2:optionalCallback})", - "description": "resizeWindow" - }, - "setWindowPosition": { - "prefix": "set", - "body": "setWindowPosition(${0:offsetX}, ${1:offsetY}, ${2:optionalCallback})", - "description": "setWindowPosition" - }, - "maximizeWindow": { - "prefix": "max", - "body": "maximizeWindow(${0:optionalCallback})", - "description": "maximizeWindow" - }, - "saveScreenshot": { - "prefix": "save", - "body": "saveScreenshot(${0:fileName}, ${1:optionalCallback})", - "description": "saveScreenshot" - }, - "getTitle": { - "prefix": "get", - "body": "getTitle(${0:callback})", - "description": "getTitle" - }, - "closeWindow": { - "prefix": "clo", - "body": "closeWindow(${0:optionalCallback})", - "description": "closeWindow" - }, - "init": { - "prefix": "in", - "body": "init(${0:URL}, ${1:optionalCallback})", - "description": "init" - }, - "urlHash": { - "prefix": "url", - "body": "urlHash(${0:hash}, ${1:optionalCallback})", - "description": "urlHash" - }, - "getCookies": { - "prefix": "get", - "body": "getCookies(${0:callback})", - "description": "getCookies" - }, - "getCookie": { - "prefix": "get", - "body": "getCookie(${0:cookieName}, ${1:callback})", - "description": "getCookie" - }, - "setCookie": { - "prefix": "set", - "body": "setCookie(${0:cookieObject}, ${1:optionalCallback})", - "description": "setCookie" - }, - "deleteCookie": { - "prefix": "del", - "body": "deleteCookie(${0:cookieName}, ${1:callback})", - "description": "deleteCookie" - }, - "deleteCookies": { - "prefix": "del", - "body": "deleteCookies(${0:optionalCallback})", - "description": "deleteCookies" - }, - "injectScript": { - "prefix": "inj", - "body": "injectScript(${0:scriptUrl}, ${1:id}, ${2:optionalCallback})", - "description": "injectScript" - }, - "getLogTypes": { - "prefix": "get", - "body": "getLogTypes(${0:callback})", - "description": "getLogTypes" - }, - "getLog": { - "prefix": "get", - "body": "getLog(${0:typeString}, ${1:callback})", - "description": "getLog" - }, - "isLogAvailable": { - "prefix": "is", - "body": "isLogAvailable(${0:typeString}, ${1:callback})", - "description": "isLogAvailable" - } + "end": { + "prefix": "end", + "body": "end(${0:optionalCallback})", + "description": "end(optionalCallback)" + }, + "pause": { + "prefix": "pause", + "body": "pause(${0:1000ms}, ${1:optionalCallback})", + "description": "pause(timems, optionalCallback)" + }, + "perform": { + "prefix": "per", + "body": "perform(${0:optionalCallback})", + "description": "perform(optionalCallback)" + }, + "useCss": { + "prefix": "usec", + "body": "useCss(${0:optionalCallback})", + "description": "useCss(optionalCallback" + }, + "useXpath": { + "prefix": "usex", + "body": "useXpath(${0:optionalCallback})", + "description": "useXpath(optionalCallback)" + }, + "switchWindow": { + "prefix": "swiw", + "body": "switchWindow(${0:handleOrName}, ${1:optionalCallback})", + "description": "switchWindow(handleOrName, optionalCallback)" + }, + "resizeWindow": { + "prefix": "resw", + "body": "resizeWindow(${0:width}, ${1:height}, ${2:optionalCallback})", + "description": "resizeWindow(width, height, optionalCallback)" + }, + "setWindowPosition": { + "prefix": "setw", + "body": "setWindowPosition(${0:offsetX}, ${1:offsetY}, ${2:optionalCallback})", + "description": "setWindowPosition(offsetX, offsetY, optionalCallback)" + }, + "maximizeWindow": { + "prefix": "maxw", + "body": "maximizeWindow(${0:optionalCallback})", + "description": "maximizeWindow(optionalCallback)" + }, + "saveScreenshot": { + "prefix": "saves", + "body": "saveScreenshot(${0:fileName}, ${1:optionalCallback})", + "description": "saveScreenshot(fileName, optionalCallback)" + }, + "getTitle": { + "prefix": "gett", + "body": "getTitle(${0:callback})", + "description": "getTitle(callback)" + }, + "closeWindow": { + "prefix": "clow", + "body": "closeWindow(${0:optionalCallback})", + "description": "closeWindow(optionalCallback)" + }, + "init": { + "prefix": "in", + "body": "init(${0:URL}, ${1:optionalCallback})", + "description": "init(URL, optionalCallback)" + }, + "urlHash": { + "prefix": "urlh", + "body": "urlHash(${0:hash}, ${1:optionalCallback})", + "description": "urlHash(hash, optionalCallback)" + }, + "getCookies": { + "prefix": "getcs", + "body": "getCookies(${0:callback})", + "description": "getCookies(callback)" + }, + "getCookie": { + "prefix": "getc", + "body": "getCookie(${0:cookieName}, ${1:callback})", + "description": "getCookie(cookieName, callback)" + }, + "setCookie": { + "prefix": "setc", + "body": "setCookie(${0:cookieObject}, ${1:optionalCallback})", + "description": "setCookie(cookieObject, optionalCallback)" + }, + "deleteCookie": { + "prefix": "delc", + "body": "deleteCookie(${0:cookieName}, ${1:callback})", + "description": "deleteCookie(cookieName, callback)" + }, + "deleteCookies": { + "prefix": "delcs", + "body": "deleteCookies(${0:optionalCallback})", + "description": "deleteCookies(optionalCallback)" + }, + "injectScript": { + "prefix": "injs", + "body": "injectScript(${0:scriptUrl}, ${1:id}, ${2:optionalCallback})", + "description": "injectScript(scriptUrl, id, optionalCallback)" + }, + "getLogTypes": { + "prefix": "getlt", + "body": "getLogTypes(${0:callback})", + "description": "getLogTypes(callback)" + }, + "getLog": { + "prefix": "getl", + "body": "getLog(${0:typeString}, ${1:callback})", + "description": "getLog(typeString, callback)" + }, + "isLogAvailable": { + "prefix": "isla", + "body": "isLogAvailable(${0:typeString}, ${1:callback})", + "description": "isLogAvailable(typeString, callback)" + }, + "click": { + "prefix": "cli", + "body": "click(${0:selector}, ${1:optionalCallback})", + "description": "click(selector, optionalCallback)" + }, + "clearValue": { + "prefix": "clev", + "body": "clearValue(${0:selector}, ${1:optionalCallback})", + "description": "clearValue(selector, optionalCallback)" + }, + "getAttribute": { + "prefix": "geta", + "body": "getAttribute(${0:selector}, ${1:attribute}, ${2:callback})", + "description": "getAttribute(selector, attribute, callback)" + }, + "getCssProperty": { + "prefix": "getcp", + "body": "getCssProperty(${0:selector}, ${1:cssProperty}, ${2:callback})", + "description": "getCssProperty(selector, cssProperty, callback)" + }, + "getElementSize": { + "prefix": "getes", + "body": "getElementSize(${0:selector}, ${1:callback})", + "description": "getElementSize(selector, callback)" + }, + "getLocation": { + "prefix": "getl", + "body": "getLocation(${0:selector}, ${1:callback})", + "description": "getLocation(selector, callback)" + }, + "getLocationInView": { + "prefix": "getlv", + "body": "getLocationInView(${0:selector}, ${1:callback})", + "description": "getLocationInView(selector, callback)" + }, + "getTagName": { + "prefix": "getta", + "body": "getTagName(${0:selector}, ${1:callback})", + "description": "getTagName(selector, callback)" + }, + "getText": { + "prefix": "gett", + "body": "getText(${0:selector}, ${1:callback})", + "description": "getText(selector, callback)" + }, + "getValue": { + "prefix": "getv", + "body": "getValue(${0:selector}, ${1:callback})", + "description": "getValue(selector, callback)" + }, + "isVisible": { + "prefix": "isv", + "body": "isVisible(${0:selector}, ${1:callback})", + "description": "isVisible(selector, callback)" + }, + "moveToElement": { + "prefix": "movte", + "body": "moveToElement(${0:selector}, ${1:xoffset}, ${2:yoffset}, ${3:optionalCallback})", + "description": "moveToElement(selector, xoffset, yoffset, optionalCallback)" + }, + "setValue": { + "prefix": "setv", + "body": "setValue(${0:selector}, ${1:inputValue}, ${2:optionalCallback})", + "description": "setValue(selector, inputValue, optionalCallback)" + }, + "submitForm": { + "prefix": "subf", + "body": "submitForm(${0:selector}, ${1:optionalCallback})", + "description": "submitForm(selector, optionalCallback)" + }, + "attributeContains": { + "prefix": "attc", + "body": "attributeContains(${0:selector}, ${1:attribute}, ${2:expected}, ${3:optionalMessage})", + "description": "attributeContains(selector, attribute, expected, optionalMessage)" + }, + "attributeEquals": { + "prefix": "atte", + "body": "attributeEquals(${0:selector}, ${1:attribute}, ${2:expected}, ${3:optionalMessage})", + "description": "attributeEquals(selector, attribute, expected, optionalMessage)" + }, + "containsText": { + "prefix": "contt", + "body": "containsText(${0:selector}, ${1:expectedText}, ${2:optionalMessage})", + "description": "containsText(selector, expectedText, optionalMessage)" + }, + "cssClassNotPresent": { + "prefix": "csscnp", + "body": "cssClassNotPresent(${0:selector}, ${1:className}, ${2:optionalMessage})", + "description": "cssClassNotPresent(selector, className, optionalMessage)" + }, + "cssClassPresent": { + "prefix": "csscp", + "body": "cssClassPresent(${0:selector}, ${1:className}, ${2:optionalMessage})", + "description": "cssClassPresent(selector, className, optionalMessage)" + }, + "cssProperty": { + "prefix": "cssp", + "body": "cssProperty(${0:selector}, ${1:cssProperty}, ${2:expected}, ${3:optionalMessage})", + "description": "cssProperty(selector, cssProperty, expected, optionalMessage)" + }, + "elementNotPresent": { + "prefix": "elemnp", + "body": "elementNotPresent(${0:selector}, ${1:optionalMessage})", + "description": "elementNotPresent(selector, optionalMessage)" + }, + "elementPresent": { + "prefix": "elemp", + "body": "elementPresent(${0:selector}, ${1:optionalMessage})", + "description": "elementPresent(selector, optionalMessage)" + }, + "hidden": { + "prefix": "hid", + "body": "hidden(${0:selector}, ${1:optionalMessage})", + "description": "hidden(selector, optionalMessage)" + }, + "title": { + "prefix": "titl", + "body": "title(${0:expected}, ${1:optionalMessage})", + "description": "title(expected, optionalMessage)" + }, + "titleContains": { + "prefix": "titlec", + "body": "titleContains(${0:expected}, ${1:optionalMessage})", + "description": "titleContains(expected, optionalMessage)" + }, + "urlContains": { + "prefix": "urlc", + "body": "urlContains(${0:expected}, ${1:optionalMessage})", + "description": "urlContains(expected, optionalMessage)" + }, + "urlEquals": { + "prefix": "urle", + "body": "urlEquals(${0:expected}, ${1:optionalMessage})", + "description": "urlEquals(expected, optionalMessage)" + }, + "value": { + "prefix": "val", + "body": "value(${0:expected}, ${1:optionalMessage})", + "description": "value(expected, optionalMessage)" + }, + "valueContains": { + "prefix": "valueco", + "body": "valueContains(${0:selector}, ${1:expected}, ${2:optionalMessage})", + "description": "valueContains(selector, expected, optionalMessage)" + }, + "visible": { + "prefix": "visi", + "body": "visible(${0:selector}, ${1:optionalMessage})", + "description": "visible(selector, optionalMessage)" + }, + "waitForElementNotPresent": { + "prefix": "waitenp", + "body": "waitForElementNotPresent(${0:selector}, ${1:time})", + "description": "waitForElementNotPresent(selector, time)" + }, + "waitForElementNotVisible": { + "prefix": "waitenv", + "body": "waitForElementNotVisible(${0:selector}, ${1:time})", + "description": "waitForElementNotVisible(selector, time)" + }, + "waitForElementPresent": { + "prefix": "waitep", + "body": "waitForElementPresent(${0:selector}, ${1:time})", + "description": "waitForElementPresent(selector, time)" + }, +"waitForElementVisible": { + "prefix": "waitev", + "body": "waitForElementVisible(${0:selector}, ${1:time})", + "description": "waitForElementVisible(selector, time)" + } } \ No newline at end of file From ae4374f7b3e9af1719595c7bec634fc6636aad33 Mon Sep 17 00:00:00 2001 From: spnraju Date: Sun, 11 Nov 2018 16:06:52 +0530 Subject: [PATCH 6/7] update readme and changelog --- CHANGELOG.md | 4 ++++ README.md | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++++ package.json | 4 ++-- 3 files changed, 69 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ddd0fa0..0d77533 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## [0.2.0] - 11-11-2018 (DD-MM-YYYY) +### Update +- add client commands and assertions + ## [0.1.1] - 10-11-2018 (DD-MM-YYYY) ### Update - fix package.json with keywords diff --git a/README.md b/README.md index 201c994..22f42d3 100644 --- a/README.md +++ b/README.md @@ -3,3 +3,66 @@ [![Version](https://vsmarketplacebadge.apphb.com/version/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) [![Installs](https://vsmarketplacebadge.apphb.com/installs/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) [![Ratings](https://vsmarketplacebadge.apphb.com/rating/Raju.vscode-nightwatchjs-snippets.svg)](https://marketplace.visualstudio.com/items?itemName=Raju.vscode-nightwatchjs-snippets) + +## The below commands are supported in this version + +* attributeContains(selector, attribute, expected, optionalMessage) +* attributeEquals(selector, attribute, expected, optionalMessage) +* containsText(selector, expectedText, optionalMessage) +* cssClassNotPresent(selector, className, optionalMessage) +* cssClassPresent(selector, className, optionalMessage) +* cssProperty(selector, cssProperty, expected, optionalMessage) +* elementNotPresent(selector, optionalMessage) +* elementPresent(selector, optionalMessage) +* hidden(selector, optionalMessage) +* title(expected, optionalMessage) +* titleContains(expected, optionalMessage) +* urlContains(expected, optionalMessage) +* urlEquals(expected, optionalMessage) +* value(expected, optionalMessage) +* valueContains(selector, expected, optionalMessage) +* visible(selector, optionalMessage) + +* waitForElementNotPresent(selector, time) +* waitForElementNotVisible(selector, time) +* waitForElementPresent(selector, time) +* waitForElementVisible(selector, time) + +* click(selector, optionalCallback) +* clearValue(selector, optionalCallback) +* getAttribute(selector, attribute, callback) +* getCssProperty(selector, cssProperty, callback) +* getElementSize(selector, callback) +* getLocation(selector, callback) +* getLocationInView(selector, callback) +* getTagName(selector, callback) +* getText(selector, callback) +* getValue(selector, callback) +* isVisible(selector, callback) +* moveToElement(selector, xoffset, yoffset, optionalCallback) +* setValue(selector, inputValue, optionalCallback) +* submitForm(selector, optionalCallback) + +* end(optionalCallback) +* pause(1000ms, optionalCallback) +* perform(optionalCallback) +* useCss(optionalCallback) +* useXpath(optionalCallback) +* switchWindow(handleOrName, optionalCallback) +* resizeWindow(width, height, optionalCallback) +* setWindowPosition(offsetX, offsetY, optionalCallback) +* maximizeWindow(optionalCallback) +* saveScreenshot(fileName, optionalCallback) +* getTitle(callback) +* closeWindow(optionalCallback) +* init(URL, optionalCallback) +* urlHash(hash, optionalCallback) +* getCookies(callback) +* getCookie(cookieName, callback) +* setCookie(cookie object, optionalCallback) +* deleteCookie(cookieName, callback) +* deleteCookies(optionalCallback) +* injectScript(scriptUrl, id, optionalCallback) +* getLogTypes(callback) +* getLog(typeString, callback) +* isLogAvailable(typeString, callback) \ No newline at end of file diff --git a/package.json b/package.json index 2eef28c..ca12320 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,8 @@ { "name": "vscode-nightwatchjs-snippets", - "version": "0.1.1", + "version": "0.2.0", "description": "NightwatchJS code snippets for Visual Studio Code", - "displayName": "NightwatchJS snippets for VS Code", + "displayName": "NightwatchJS snippets", "publisher": "Raju", "keywords": [ "nightwatchjs", From 02c297ce61bf16f55420fae4a1eb80ebfaecb55a Mon Sep 17 00:00:00 2001 From: spnraju Date: Sun, 11 Nov 2018 16:16:21 +0530 Subject: [PATCH 7/7] update readme with more details --- README.md | 114 +++++++++++++++++++++++++++--------------------------- 1 file changed, 57 insertions(+), 57 deletions(-) diff --git a/README.md b/README.md index 22f42d3..c2e31a7 100644 --- a/README.md +++ b/README.md @@ -6,63 +6,63 @@ ## The below commands are supported in this version -* attributeContains(selector, attribute, expected, optionalMessage) -* attributeEquals(selector, attribute, expected, optionalMessage) -* containsText(selector, expectedText, optionalMessage) -* cssClassNotPresent(selector, className, optionalMessage) -* cssClassPresent(selector, className, optionalMessage) -* cssProperty(selector, cssProperty, expected, optionalMessage) -* elementNotPresent(selector, optionalMessage) -* elementPresent(selector, optionalMessage) -* hidden(selector, optionalMessage) -* title(expected, optionalMessage) -* titleContains(expected, optionalMessage) -* urlContains(expected, optionalMessage) -* urlEquals(expected, optionalMessage) -* value(expected, optionalMessage) -* valueContains(selector, expected, optionalMessage) -* visible(selector, optionalMessage) +* **attributeContains**(selector, attribute, expected, optionalMessage) +* **attributeEquals**(selector, attribute, expected, optionalMessage) +* **containsText**(selector, expectedText, optionalMessage) +* **cssClassNotPresent**(selector, className, optionalMessage) +* **cssClassPresent**(selector, className, optionalMessage) +* **cssProperty**(selector, cssProperty, expected, optionalMessage) +* **elementNotPresent**(selector, optionalMessage) +* **elementPresent**(selector, optionalMessage) +* **hidden**(selector, optionalMessage) +* **title**(expected, optionalMessage) +* **titleContains**(expected, optionalMessage) +* **urlContains**(expected, optionalMessage) +* **urlEquals**(expected, optionalMessage) +* **value**(expected, optionalMessage) +* **valueContains**(selector, expected, optionalMessage) +* **visible**(selector, optionalMessage) -* waitForElementNotPresent(selector, time) -* waitForElementNotVisible(selector, time) -* waitForElementPresent(selector, time) -* waitForElementVisible(selector, time) +* **waitForElementNotPresent**(selector, time) +* **waitForElementNotVisible**(selector, time) +* **waitForElementPresent**(selector, time) +* **waitForElementVisible**(selector, time) -* click(selector, optionalCallback) -* clearValue(selector, optionalCallback) -* getAttribute(selector, attribute, callback) -* getCssProperty(selector, cssProperty, callback) -* getElementSize(selector, callback) -* getLocation(selector, callback) -* getLocationInView(selector, callback) -* getTagName(selector, callback) -* getText(selector, callback) -* getValue(selector, callback) -* isVisible(selector, callback) -* moveToElement(selector, xoffset, yoffset, optionalCallback) -* setValue(selector, inputValue, optionalCallback) -* submitForm(selector, optionalCallback) +* **click**(selector, optionalCallback) +* **clearValue**(selector, optionalCallback) +* **getAttribute**(selector, attribute, callback) +* **getCssProperty**(selector, cssProperty, callback) +* **getElementSize**(selector, callback) +* **getLocation**(selector, callback) +* **getLocationInView**(selector, callback) +* **getTagName**(selector, callback) +* **getText**(selector, callback) +* **getValue**(selector, callback) +* **isVisible**(selector, callback) +* **moveToElement**(selector, xoffset, yoffset, optionalCallback) +* **setValue**(selector, inputValue, optionalCallback) +* **submitForm**(selector, optionalCallback) -* end(optionalCallback) -* pause(1000ms, optionalCallback) -* perform(optionalCallback) -* useCss(optionalCallback) -* useXpath(optionalCallback) -* switchWindow(handleOrName, optionalCallback) -* resizeWindow(width, height, optionalCallback) -* setWindowPosition(offsetX, offsetY, optionalCallback) -* maximizeWindow(optionalCallback) -* saveScreenshot(fileName, optionalCallback) -* getTitle(callback) -* closeWindow(optionalCallback) -* init(URL, optionalCallback) -* urlHash(hash, optionalCallback) -* getCookies(callback) -* getCookie(cookieName, callback) -* setCookie(cookie object, optionalCallback) -* deleteCookie(cookieName, callback) -* deleteCookies(optionalCallback) -* injectScript(scriptUrl, id, optionalCallback) -* getLogTypes(callback) -* getLog(typeString, callback) -* isLogAvailable(typeString, callback) \ No newline at end of file +* **end**(optionalCallback) +* **pause**(1000ms, optionalCallback) +* **perform**(optionalCallback) +* **useCss**(optionalCallback) +* **useXpath**(optionalCallback) +* **switchWindow**(handleOrName, optionalCallback) +* **resizeWindow**(width, height, optionalCallback) +* **setWindowPosition**(offsetX, offsetY, optionalCallback) +* **maximizeWindow**(optionalCallback) +* **saveScreenshot**(fileName, optionalCallback) +* **getTitle**(callback) +* **closeWindow**(optionalCallback) +* **init**(URL, optionalCallback) +* **urlHash**(hash, optionalCallback) +* **getCookies**(callback) +* **getCookie**(cookieName, callback) +* **setCookie**(cookie object, optionalCallback) +* **deleteCookie**(cookieName, callback) +* **deleteCookies**(optionalCallback) +* **injectScript**(scriptUrl, id, optionalCallback) +* **getLogTypes**(callback) +* **getLog**(typeString, callback) +* **isLogAvailable**(typeString, callback) \ No newline at end of file