Skip to content

Commit

Permalink
🐛 FIX: Snippets
Browse files Browse the repository at this point in the history
  • Loading branch information
ortoniKC committed Oct 23, 2020
1 parent 7bae603 commit b98d1c1
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions panelconfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ function javaSnippet(type, codeType, codeValue, variable, isPOM) {
// getAttribute Collection based XPath //input[@placeholder='first name & last name'] firstName" false
switch (codeType) {
case "CSS":
str = `driver.findElement(By.css("${codeValue}"))`;
str = `driver.findElement(By.cssSelector("${codeValue}"))`;
break;
case "Unique Class Atrribute":
str = `driver.findElement(By.className("${codeValue}"))`;
Expand Down Expand Up @@ -201,13 +201,12 @@ function jsSnippet(type, codeType, codeValue, variable) {
}
switch (type) {
case "click":
str = 'this.click(' + str + ');';
// str += `.click();`
str += `.click();`
// str = `private ${variable} = ${str}`
break;
case "sendKeys":
// str = `private ${variable} = ${str}`
str = `this.clearAndType(${str});`
str += `.sendKeys()`
break;
case "getAttribute":
str += `.getAttribute();`
Expand Down

0 comments on commit b98d1c1

Please sign in to comment.