[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kate/frameworks] /: fix viemulatedcommandbar tests
From:       Michal Humpula <michal.humpula () seznam ! cz>
Date:       2013-12-31 19:11:19
Message-ID: E1Vy4il-0005px-UJ () scm ! kde ! org
[Download RAW message or body]

Git commit efac51e1b2f5288d0fce425e17ff00aa0684a011 by Michal Humpula.
Committed on 31/12/2013 at 18:56.
Pushed by michalhumpula into branch 'frameworks'.

fix viemulatedcommandbar tests

M  +5    -0    part/vimode/kateviemulatedcommandbar.cpp
M  +2    -0    tests/vimode_test.cpp

http://commits.kde.org/kate/efac51e1b2f5288d0fce425e17ff00aa0684a011

diff --git a/part/vimode/kateviemulatedcommandbar.cpp b/part/vimode/kateviemulatedcommandbar.cpp
index a18bfa5..87b161c 100644
--- a/part/vimode/kateviemulatedcommandbar.cpp
+++ b/part/vimode/kateviemulatedcommandbar.cpp
@@ -1106,6 +1106,11 @@ bool KateViEmulatedCommandBar::handleKeyPress(const QKeyEvent* keyEvent)
       m_edit->setCursorPosition(0);
       return true;
     }
+    else if (keyEvent->key() == Qt::Key_E)
+    {
+      m_edit->setCursorPosition(m_edit->text().length());
+      return true;
+    }
     else if (keyEvent->key() == Qt::Key_W)
     {
       deleteSpacesToLeftOfCursor();
diff --git a/tests/vimode_test.cpp b/tests/vimode_test.cpp
index 5e52986..eca1e51 100644
--- a/tests/vimode_test.cpp
+++ b/tests/vimode_test.cpp
@@ -7314,6 +7314,8 @@ void ViModeTest::waitForEmulatedCommandBarToHide(long int timeout)
   {
     QApplication::processEvents();
   }
+  //FIXME: seems like this debug message helps to pass a test... wtf?
+  qDebug() << "waited: " << waitStartedTime.msecsTo(QDateTime::currentDateTime());
   QVERIFY(!emulatedCommandBar()->isVisible());
 }
 
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic