jenkins-bot submitted this change.

View Change

Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
[bugfix] Solve AttributeError: module 'pywikibot.data' has no attribute 'mysql'

Change-Id: I6c28553075b3af03e6b3531bb3af8430c7826b5b
---
M tests/mysql_tests.py
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/mysql_tests.py b/tests/mysql_tests.py
index 9e921be..3ed689c 100644
--- a/tests/mysql_tests.py
+++ b/tests/mysql_tests.py
@@ -9,7 +9,6 @@

import unittest

-from pywikibot import data

from tests.aspects import TestCase, require_modules

@@ -23,7 +22,8 @@

def test_mysql(self):
"""Test data.mysql.mysql_query function."""
- result = data.mysql.mysql_query('test')
+ from pywikibot.data.mysql import mysql_query
+ result = mysql_query('test')
self.assertIsInstance(result, GeneratorType)
self.assertEqual(next(result), 'test')


To view, visit change 678323. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: I6c28553075b3af03e6b3531bb3af8430c7826b5b
Gerrit-Change-Number: 678323
Gerrit-PatchSet: 1
Gerrit-Owner: Xqt <info@gno.de>
Gerrit-Reviewer: Xqt <info@gno.de>
Gerrit-Reviewer: jenkins-bot
Gerrit-MessageType: merged