Skip to content

Instantly share code, notes, and snippets.

@SarahElson
Created August 9, 2024 10:33
Show Gist options
  • Save SarahElson/2b550ab21e2ae29da44d93cd1fa6bdbc to your computer and use it in GitHub Desktop.
Save SarahElson/2b550ab21e2ae29da44d93cd1fa6bdbc to your computer and use it in GitHub Desktop.
Python Assert Keyword: A Complete Guide
from selenium import webdriver
from base import SampleTest
import unittest
class DataIntegrityTest(SampleTest):
def test_data_integration(self):
driver = self.driver
driver.get("https://ecommerce-playground.lambdatest.io/index.php?route=common/home")
assert "Your Store" in driver.title, "Website title is not as expected"
if __name__ == "__main__":
unittest.main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment