mirror of
https://github.com/altlinux/admc.git
synced 2025-02-19 01:58:09 +03:00
clang-format
This commit is contained in:
parent
5d3dbbb6d7
commit
e69c43ce5b
@ -22,21 +22,21 @@
|
|||||||
|
|
||||||
#include "adldap.h"
|
#include "adldap.h"
|
||||||
#include "console_types/console_object.h"
|
#include "console_types/console_object.h"
|
||||||
#include "globals.h"
|
|
||||||
#include "utils.h"
|
|
||||||
#include "select_object_dialog.h"
|
|
||||||
#include "select_object_advanced_dialog.h"
|
|
||||||
#include "filter_widget/filter_widget_simple_tab.h"
|
#include "filter_widget/filter_widget_simple_tab.h"
|
||||||
#include "filter_widget/select_base_widget.h"
|
#include "filter_widget/select_base_widget.h"
|
||||||
|
#include "globals.h"
|
||||||
#include "select_container_dialog.h"
|
#include "select_container_dialog.h"
|
||||||
|
#include "select_object_advanced_dialog.h"
|
||||||
|
#include "select_object_dialog.h"
|
||||||
|
#include "utils.h"
|
||||||
|
|
||||||
|
#include <QLineEdit>
|
||||||
#include <QMessageBox>
|
#include <QMessageBox>
|
||||||
#include <QModelIndex>
|
#include <QModelIndex>
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
#include <QTest>
|
#include <QTest>
|
||||||
#include <QTimer>
|
#include <QTimer>
|
||||||
#include <QTreeView>
|
#include <QTreeView>
|
||||||
#include <QLineEdit>
|
|
||||||
|
|
||||||
#define PRINT_FOCUS_WIDGET_BEFORE_TAB false
|
#define PRINT_FOCUS_WIDGET_BEFORE_TAB false
|
||||||
#define PRINT_FOCUS_WIDGET_AFTER_TAB false
|
#define PRINT_FOCUS_WIDGET_AFTER_TAB false
|
||||||
@ -239,7 +239,7 @@ void ADMCTest::select_in_select_dialog(SelectObjectDialog *select_dialog, const
|
|||||||
void ADMCTest::select_object_dialog_select(const QString &dn) {
|
void ADMCTest::select_object_dialog_select(const QString &dn) {
|
||||||
auto select_dialog = parent_widget->findChild<SelectObjectDialog *>();
|
auto select_dialog = parent_widget->findChild<SelectObjectDialog *>();
|
||||||
QVERIFY(select_dialog != nullptr);
|
QVERIFY(select_dialog != nullptr);
|
||||||
|
|
||||||
auto select_base_widget = select_dialog->findChild<SelectBaseWidget *>();
|
auto select_base_widget = select_dialog->findChild<SelectBaseWidget *>();
|
||||||
QVERIFY(select_base_widget != nullptr);
|
QVERIFY(select_base_widget != nullptr);
|
||||||
select_base_widget_add(select_base_widget, test_arena_dn());
|
select_base_widget_add(select_base_widget, test_arena_dn());
|
||||||
|
@ -93,9 +93,9 @@ protected:
|
|||||||
|
|
||||||
// This is for message boxes opened using exec(), i.e.
|
// This is for message boxes opened using exec(), i.e.
|
||||||
// the ones opened by message box static f-ns. Message
|
// the ones opened by message box static f-ns. Message
|
||||||
// boxes block executation because they are // opened
|
// boxes block executation because they are opened using
|
||||||
// using exec(). Therefore when testing f-ns that can
|
// exec(). Therefore when testing f-ns that can open
|
||||||
// open messageboxes, call this to to close messageboxes
|
// messageboxes, call this to to close messageboxes
|
||||||
// later.
|
// later.
|
||||||
void close_message_box_later();
|
void close_message_box_later();
|
||||||
|
|
||||||
@ -112,7 +112,6 @@ protected:
|
|||||||
void select_object_dialog_select(const QString &dn);
|
void select_object_dialog_select(const QString &dn);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
void navigate_until_object(QTreeView *view, const QString &target_dn, const int dn_role);
|
void navigate_until_object(QTreeView *view, const QString &target_dn, const int dn_role);
|
||||||
|
@ -23,14 +23,14 @@
|
|||||||
#include "editors/multi_editor.h"
|
#include "editors/multi_editor.h"
|
||||||
#include "editors/string_editor.h"
|
#include "editors/string_editor.h"
|
||||||
|
|
||||||
#include <QVBoxLayout>
|
|
||||||
#include <QString>
|
|
||||||
#include <QStandardItemModel>
|
|
||||||
#include <QPushButton>
|
|
||||||
#include <QDialog>
|
|
||||||
#include <QCheckBox>
|
#include <QCheckBox>
|
||||||
|
#include <QDialog>
|
||||||
#include <QLineEdit>
|
#include <QLineEdit>
|
||||||
|
#include <QPushButton>
|
||||||
|
#include <QStandardItemModel>
|
||||||
|
#include <QString>
|
||||||
#include <QTreeView>
|
#include <QTreeView>
|
||||||
|
#include <QVBoxLayout>
|
||||||
|
|
||||||
// NOTE: can't be set because order is important. Read only
|
// NOTE: can't be set because order is important. Read only
|
||||||
// has to be set first to enable other filters.
|
// has to be set first to enable other filters.
|
||||||
@ -150,7 +150,7 @@ void ADMCTestAttributesTab::filter() {
|
|||||||
// changes
|
// changes
|
||||||
void ADMCTestAttributesTab::apply() {
|
void ADMCTestAttributesTab::apply() {
|
||||||
const QString correct_value = "test description";
|
const QString correct_value = "test description";
|
||||||
|
|
||||||
navigate_until_object(view, "description", Qt::DisplayRole);
|
navigate_until_object(view, "description", Qt::DisplayRole);
|
||||||
edit_button->click();
|
edit_button->click();
|
||||||
|
|
||||||
|
@ -31,7 +31,7 @@ class QPushButton;
|
|||||||
class QTreeView;
|
class QTreeView;
|
||||||
|
|
||||||
class ADMCTestAttributesTab : public ADMCTest {
|
class ADMCTestAttributesTab : public ADMCTest {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void init() override;
|
void init() override;
|
||||||
|
@ -23,10 +23,10 @@
|
|||||||
#include "select_object_dialog.h"
|
#include "select_object_dialog.h"
|
||||||
#include "tabs/membership_tab.h"
|
#include "tabs/membership_tab.h"
|
||||||
|
|
||||||
#include <QVBoxLayout>
|
|
||||||
#include <QStandardItemModel>
|
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
|
#include <QStandardItemModel>
|
||||||
#include <QTreeView>
|
#include <QTreeView>
|
||||||
|
#include <QVBoxLayout>
|
||||||
|
|
||||||
// TODO: test primary functionality
|
// TODO: test primary functionality
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@ class QStandardItemModel;
|
|||||||
class QPushButton;
|
class QPushButton;
|
||||||
|
|
||||||
class ADMCTestMemberOfTab : public ADMCTest {
|
class ADMCTestMemberOfTab : public ADMCTest {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void init() override;
|
void init() override;
|
||||||
|
@ -23,10 +23,10 @@
|
|||||||
#include "select_object_dialog.h"
|
#include "select_object_dialog.h"
|
||||||
#include "tabs/membership_tab.h"
|
#include "tabs/membership_tab.h"
|
||||||
|
|
||||||
#include <QVBoxLayout>
|
|
||||||
#include <QStandardItemModel>
|
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
|
#include <QStandardItemModel>
|
||||||
#include <QTreeView>
|
#include <QTreeView>
|
||||||
|
#include <QVBoxLayout>
|
||||||
|
|
||||||
// TODO: test primary functionality
|
// TODO: test primary functionality
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@ class QStandardItemModel;
|
|||||||
class QPushButton;
|
class QPushButton;
|
||||||
|
|
||||||
class ADMCTestMembersTab : public ADMCTest {
|
class ADMCTestMembersTab : public ADMCTest {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void init() override;
|
void init() override;
|
||||||
|
@ -23,27 +23,27 @@
|
|||||||
#include "adldap.h"
|
#include "adldap.h"
|
||||||
#include "console_types/console_object.h"
|
#include "console_types/console_object.h"
|
||||||
#include "create_object_dialog.h"
|
#include "create_object_dialog.h"
|
||||||
|
#include "filter_widget/filter_widget_advanced_tab.h"
|
||||||
|
#include "filter_widget/filter_widget_simple_tab.h"
|
||||||
#include "find_object_dialog.h"
|
#include "find_object_dialog.h"
|
||||||
#include "select_object_advanced_dialog.h"
|
|
||||||
#include "find_widget.h"
|
#include "find_widget.h"
|
||||||
#include "move_object_dialog.h"
|
#include "move_object_dialog.h"
|
||||||
#include "password_dialog.h"
|
#include "password_dialog.h"
|
||||||
#include "rename_object_dialog.h"
|
#include "rename_object_dialog.h"
|
||||||
#include "select_container_dialog.h"
|
#include "select_container_dialog.h"
|
||||||
|
#include "select_object_advanced_dialog.h"
|
||||||
#include "select_object_dialog.h"
|
#include "select_object_dialog.h"
|
||||||
#include "filter_widget/filter_widget_simple_tab.h"
|
|
||||||
#include "filter_widget/filter_widget_advanced_tab.h"
|
|
||||||
#include "utils.h"
|
#include "utils.h"
|
||||||
|
|
||||||
#include <QComboBox>
|
#include <QComboBox>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
|
#include <QLineEdit>
|
||||||
#include <QModelIndex>
|
#include <QModelIndex>
|
||||||
|
#include <QPlainTextEdit>
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
|
#include <QTabWidget>
|
||||||
#include <QTest>
|
#include <QTest>
|
||||||
#include <QTreeView>
|
#include <QTreeView>
|
||||||
#include <QPlainTextEdit>
|
|
||||||
#include <QTabWidget>
|
|
||||||
#include <QLineEdit>
|
|
||||||
|
|
||||||
void ADMCTestObjectMenu::object_menu_new_user() {
|
void ADMCTestObjectMenu::object_menu_new_user() {
|
||||||
const QString name = TEST_USER;
|
const QString name = TEST_USER;
|
||||||
|
@ -41,7 +41,6 @@ private slots:
|
|||||||
void object_menu_find_advanced();
|
void object_menu_find_advanced();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* ADMC_TEST_OBJECT_MENU_H */
|
#endif /* ADMC_TEST_OBJECT_MENU_H */
|
||||||
|
@ -21,13 +21,13 @@
|
|||||||
#include "admc_test_select_object_dialog.h"
|
#include "admc_test_select_object_dialog.h"
|
||||||
|
|
||||||
#include "admc_test_select_base_widget.h"
|
#include "admc_test_select_base_widget.h"
|
||||||
#include "select_object_dialog.h"
|
|
||||||
#include "console_types/console_object.h"
|
#include "console_types/console_object.h"
|
||||||
#include "filter_widget/select_base_widget.h"
|
#include "filter_widget/select_base_widget.h"
|
||||||
|
#include "select_object_dialog.h"
|
||||||
|
|
||||||
#include <QLineEdit>
|
#include <QLineEdit>
|
||||||
#include <QPushButton>
|
|
||||||
#include <QMessageBox>
|
#include <QMessageBox>
|
||||||
|
#include <QPushButton>
|
||||||
#include <QTreeView>
|
#include <QTreeView>
|
||||||
|
|
||||||
void ADMCTestSelectObjectDialog::init() {
|
void ADMCTestSelectObjectDialog::init() {
|
||||||
@ -129,7 +129,7 @@ void ADMCTestSelectObjectDialog::multiple_match_duplicate() {
|
|||||||
QVERIFY(create_success2);
|
QVERIFY(create_success2);
|
||||||
|
|
||||||
select_object_in_multi_match_dialog(TEST_USER, dn2);
|
select_object_in_multi_match_dialog(TEST_USER, dn2);
|
||||||
|
|
||||||
const QList<QString> selected_first = dialog->get_selected();
|
const QList<QString> selected_first = dialog->get_selected();
|
||||||
QVERIFY(selected_first == QList<QString>({dn2}));
|
QVERIFY(selected_first == QList<QString>({dn2}));
|
||||||
|
|
||||||
@ -156,7 +156,7 @@ void ADMCTestSelectObjectDialog::select_object_in_multi_match_dialog(const QStri
|
|||||||
|
|
||||||
auto ok_button = match_dialog->findChild<QPushButton *>();
|
auto ok_button = match_dialog->findChild<QPushButton *>();
|
||||||
QVERIFY(ok_button != nullptr);
|
QVERIFY(ok_button != nullptr);
|
||||||
|
|
||||||
ok_button->click();
|
ok_button->click();
|
||||||
|
|
||||||
close_message_box();
|
close_message_box();
|
||||||
|
@ -28,7 +28,7 @@ class QPushButton;
|
|||||||
class SelectObjectDialog;
|
class SelectObjectDialog;
|
||||||
|
|
||||||
class ADMCTestSelectObjectDialog : public ADMCTest {
|
class ADMCTestSelectObjectDialog : public ADMCTest {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void init() override;
|
void init() override;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user