Report for unittest
Project description
#Introduction
Based on TheRuffianReport development,
new assertion failure screenshot,
screenshot display and DingTalk function
#Installing pip install TheRuffianReport python≥3.0
#Author bugpz2779@gmail.com
#Function Introduction
# screenshot
import unittest
from selenium import webdriver
from TheRuffianReport.HTMLTestRunner import failure_monitor
class Test_demo(unittest.TestCase):
def setUp(self) -> None:
self.driver = webdriver.Chrome()
self.failureException = failure_monitor(self, 'images')
self.driver.get('https://www.baidu.com')
def test_baidu(self):
self.driver.find_element('id', 'kw').send_keys('python')
self.driver.find_element('id', 'su').click()
self.assertEqual(self.driver.find_element('id', 'kw').get_attribute('value'), 'selenium')
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
TheRuffianReport-1.0.1.tar.gz
(12.4 kB
view hashes)
Built Distribution
Close
Hashes for TheRuffianReport-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8478ed172eb20360b85adb3af13f7838ee3e820139b52d6a494d6a9fa5ef9b60 |
|
MD5 | b7d6c04f242da47eb766d451d1212fb3 |
|
BLAKE2b-256 | f4ae002aa901bc663cb87e603bbcfe2c8f9fac7d291a5d47882c6b55f1efdb3a |