File indexing completed on 2024-05-12 05:52:03
0001 /* 0002 SPDX-FileCopyrightText: 2022 Waqar Ahmed <waqar.17a@gmail.com> 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #pragma once 0008 0009 #include "kateapp.h" 0010 0011 #include <QObject> 0012 #include <QTemporaryDir> 0013 0014 #include <memory> 0015 0016 class KateApp; 0017 class KateViewSpace; 0018 class KateViewManager; 0019 0020 class KateViewManagementTests : public QObject 0021 { 0022 Q_OBJECT 0023 0024 public: 0025 KateViewManagementTests(QObject *parent = nullptr); 0026 0027 private Q_SLOTS: 0028 void testSingleViewspaceDoesntCloseWhenLastViewClosed(); 0029 void testViewspaceClosesWhenLastViewClosed(); 0030 void testViewspaceClosesWhenThereIsWidget(); 0031 void testMoveViewBetweenViewspaces(); 0032 void testTwoMainWindowsCloseInitialDocument1(); 0033 void testTwoMainWindowsCloseInitialDocument2(); 0034 void testTwoMainWindowsCloseInitialDocument3(); 0035 void testTabLRUWithWidgets(); 0036 void testViewChangedEmittedOnAddWidget(); 0037 void testWidgetAddedEmittedOnAddWidget(); 0038 void testWidgetRemovedEmittedOnRemoveWidget(); 0039 void testActivateNotAddedWidget(); 0040 void testBug460613(); 0041 void testWindowsClosesDocuments(); 0042 void testTabBarHidesShows(); 0043 void testNewWindowHasSameGlobalOptions(); 0044 void testBug465811(); 0045 void testBug465807(); 0046 void testBug465808(); 0047 void testNewViewCreatedIfViewNotinViewspace(); 0048 void testNewSessionClearsWindowWidgets(); 0049 void testViewspaceWithWidgetDoesntCrashOnClose(); 0050 0051 private: 0052 class QTemporaryDir *m_tempdir; 0053 std::unique_ptr<KateApp> app; 0054 };