Skip to content

Instantly share code, notes, and snippets.

Z:\devel\python_training\env\Scripts\python.exe "C:\Program Files (x86)\JetBrains\PyCharm Community Edition 2016.2.3\helpers\pycharm\pytestrunner.py" -p pytest_teamcity Z:/devel/python_training/test_add_contact.py "-k test_addcontact_full"
Testing started at 16:36 ...
============================= test session starts =============================
platform win32 -- Python 3.5.2, pytest-3.0.3, py-1.4.31, pluggy-0.4.0
rootdir: Z:\devel\python_training, inifile:
collected 3 items
test_add_contact.py .
============================= 2 tests deselected ==============================
def get_contact_list(self):
wd = self.app.wd
contacts = []
rows = wd.find_elements_by_name("entry")
self.contact_page()
for row in rows:
cells = row.find_elements_by_tag_name("td")
id = cells[0].find_element_by_name("selected[]").get_attribute("value")
contacts.append(Contact(id=id))
return contacts
def get_contact_list(self):
wd = self.app.wd
self.contact_page()
contacts = []
rows = wd.find_elements_by_name("entry")
for row in rows:
cells = row.find_elements_by_tag_name("td")
id = cells[0].find_element_by_name("selected[]").get_attribute("value")
name = cells[1].text
lastname = cells[2].text
def is_there(self, part, s):
if part in s:
return re.search(part + " (.*)", s).group(1)
else:
return None
def get_contact_from_view_page(self, index):
wd = self.app.wd
self.open_contact_view_page_by_index(index)
text = wd.find_element_by_id("content").text
Z:\devel\python_training\env\Scripts\python.exe Z:/devel/python_training/check_db_connection.py
Traceback (most recent call last):
File "Z:\devel\python_training\env\lib\site-packages\pymysql\converters.py", line 20, in escape_item
encoder = mapping[text_type]
KeyError: <class 'str'>
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "Z:/devel/python_training/check_db_connection.py", line 7, in <module>
================================== FAILURES ===================================
___________________________ test_signup_new_account ___________________________
app = <fixture.application.Application object at 0x00000000047F4A58>
def test_signup_new_account(app):
username = random_username("user_", 10)
email = username + "@localhost"
password = "test"
app.james.ensure_user_exists(username, password)
Return-Path: <admin@example.com>
Delivered-To: user_deDaMRvjh@localhost
Received: from 127.0.0.1 ([127.0.0.1])
by ADMIN-PC (JAMES SMTP Server 2.3.2) with SMTP ID 971
for <user_deDaMRvjh@localhost>;
Thu, 5 Jan 2017 16:55:45 +0300 (MSK)
Subject: [MantisBT] Account registration
To: user_deDaMRvjh@localhost
X-PHP-Originating-Script: 0:class.phpmailer.php
Date: Thu, 5 Jan 2017 14:55:45 +0100
================================== FAILURES ===================================
___________________________ test_signup_new_account ___________________________
app = <fixture.application.Application object at 0x0000000003D89828>
def test_signup_new_account(app):
username = random_username("user_", 10)
email = username + "@localhost"
password = "test"
app.james.ensure_user_exists(username, password)
Started by user admin
Building in workspace C:\Users\ADMIN\.jenkins\workspace\addressbook tests
> C:\Program Files\Git\bin\git.exe rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
> C:\Program Files\Git\bin\git.exe config remote.origin.url https://github.com/alexpodoff/python_training # timeout=10
Fetching upstream changes from https://github.com/alexpodoff/python_training
> C:\Program Files\Git\bin\git.exe --version # timeout=10
> C:\Program Files\Git\bin\git.exe fetch --tags --progress https://github.com/alexpodoff/python_training +refs/heads/*:refs/remotes/origin/*
> C:\Program Files\Git\bin\git.exe rev-parse "refs/remotes/origin/master^{commit}" # timeout=10
> C:\Program Files\Git\bin\git.exe rev-parse "refs/remotes/origin/origin/master^{commit}" # timeout=10
org.openqa.selenium.WebDriverException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output:
Manager
1557145907521 addons.manager DEBUG Registering shutdown blocker for LightweightThemeManager
1557145907521 addons.manager DEBUG Provider finished startup: LightweightThemeManager
1557145907522 addons.manager DEBUG Starting provider: GMPProvider
1557145907524 addons.manager DEBUG Registering shutdown blocker for GMPProvider
1557145907524 addons.manager DEBUG Provider finished startup: GMPProvider
1557145907524 addons.manager DEBUG Starting provider: PluginProvider
1557145907524 addons.manager DEBUG Registering shutdown blocker for PluginProvider
1557145907524 addons.manager DEBUG Provider finished startup: PluginProvider