Created
August 15, 2021 10:27
-
-
Save hamzahjamad/7ce0578eb40157e346fcc8c6227dc1bf to your computer and use it in GitHub Desktop.
popcat-clicker
This file contains 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 time | |
from selenium import webdriver | |
class PythonOrgSearch(unittest.TestCase): | |
def setUp(self): | |
self.driver = webdriver.Chrome( | |
"D:\laragon\www\popcat-clicker\chromedriver.exe") | |
def test_search_in_python_org(self): | |
driver = self.driver | |
driver.get("https://popcat.click/") | |
driver.implicitly_wait(60) | |
elem = driver.find_element_by_id("app") | |
count = 0 | |
while True: | |
if count == 1000: | |
print("wait") | |
time.sleep(15) | |
count = 0 | |
elem.click() | |
print(count) | |
count = count + 1 | |
def tearDown(self): | |
self.driver.close() | |
if __name__ == "__main__": | |
unittest.main() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment