This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.lambdatest.junit; | |
public class Class1 { | |
public double conversion(double temparature, String unit){ | |
if(unit.equals("F")){ | |
return (temparature-32)*(5.0/9.0); | |
}else{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>com.lambdatest</groupId> | |
<artifactId>Single-Responsibility-Principle-In-Java</artifactId> | |
<version>0.0.1-SNAPSHOT</version> | |
<properties> | |
<java.version>8</java.version> | |
<maven.compiler.source>${java.version}</maven.compiler.source> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.lambdatest.mainpagecomponents; | |
import com.lambdatest.pagecomponents.MyAccountPage; | |
import com.lambdatest.pagecomponents.NavigationBar; | |
import com.lambdatest.pagecomponents.SearchProduct; | |
import com.lambdatest.pagecomponents.SpecialLinkBar; | |
import org.openqa.selenium.WebDriver; | |
import org.openqa.selenium.support.PageFactory; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.lambdatest.srp; | |
import com.lambdatest.base.BaseTest; | |
import com.lambdatest.mainpagecomponents.LambdaTestHomePage; | |
import org.testng.annotations.BeforeTest; | |
import org.testng.annotations.Test; | |
public class TestClass extends BaseTest { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.lambdatest.pages; | |
import org.openqa.selenium.WebDriver; | |
import org.openqa.selenium.By; | |
public class LoginPage{ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.lambdatest.test; | |
import com.lambdatest.base.BaseTest; | |
import com.lambdatest.pages.HomePage; | |
import com.lambdatest.pages.LoginPage; | |
import org.testng.annotations.Test; | |
public class TestCase extends BaseTest { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import time | |
from selenium.webdriver.common.by import By | |
from selenium import webdriver | |
username = "LT_USERNAME" | |
accessToken = "LT_ACCESS_KEY" | |
gridUrl = "hub.lambdatest.com/wd/hub" | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
import time | |
from selenium.webdriver.common.by import By | |
from selenium import webdriver | |
browser = webdriver.Chrome() | |
browser.maximize_window() | |
browser.get("https://ecommerce-playground.lambdatest.io/index.php?route=account/register") | |
time.sleep(5) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import unittest | |
import HtmlTestRunner | |
import sys | |
sys.path.append(sys.path[0] + "/..") | |
from setup.setup import testSet | |
from locators.formLocators import formWebAction | |
set_up = testSet() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from selenium.webdriver.common.by import By | |
class formLocator: | |
name = "//input[@id='name']" | |
email = "//input[@id='inputEmail4']" | |
password = "//input[@id='inputPassword4']" | |
company = "//input[@id='company']" | |
website = "//input[@id='websitename']" | |
country = "//select[@name='country']" | |
city = "//input[@id='inputCity']" |