Ejemplo n.º 1
0
 def on_connect(self):
     uri = self.uriEdit.text()
     login = self.loginEdit.text()
     password = self.passwordEdit.text()
     self.connection = DataBaseConnection(uri, login, password)
     self.loginSuccesful.emit()
     self.close()
Ejemplo n.º 2
0
 def setUpClass(cls):
     DataBaseConnection(**TestConfig.NEO4J_DATA)
Ejemplo n.º 3
0
 def setUpClass(cls):
     DataBaseConnection(**TestConfig.NEO4J_DATA)
     TextProcessor().clear_db()
     cls.app = QApplication(sys.argv)
Ejemplo n.º 4
0
 def test_connect(self):
     """
         Проверка подключения. Если не подключается, будет Exception
     """
     connection = DataBaseConnection(**TestConfig.NEO4J_DATA)
     connection.connect(**TestConfig.NEO4J_DATA)
Ejemplo n.º 5
0
 def setUpClass(cls):
     DataBaseConnection(**TestConfig.NEO4J_DATA)
     cls.processor = TextProcessor()
     cls.processor.clear_db()
Ejemplo n.º 6
0
import setup_

from api import TextProcessor
from api.database import DataBaseConnection
from api.algorithm import DictionaryAlgorithm
from ui.widgets import AlgorithmResults
from PyQt5.QtWidgets import QApplication
from tests.config import Config
import sys

if __name__ == "__main__":
    db = DataBaseConnection(**Config.NEO4J_DATA)
    proc = TextProcessor()
    alg = DictionaryAlgorithm()
    app = QApplication(sys.argv)
    widget = AlgorithmResults(alg, proc)
    widget.show()

    sys.exit(app.exec_())
Ejemplo n.º 7
0
 def setUpClass(cls):
     DataBaseConnection(**TestConfig.NEO4J_DATA)
     [node.delete() for node in TextNode.nodes.all()]