Commit 8c913aa8 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Add autotest + extract savetoolbutton

parent d5859753
Pipeline #44483 canceled with stage
......@@ -38,3 +38,4 @@ add_unittest( saverulesjobtest.cpp "")
add_unittest( kdebugsettingsloadingcategoriestest.cpp "")
add_unittest( changedebugmodejobtest.cpp "")
add_unittest( loadgroupmenutest.cpp "")
add_unittest( loadtoolbuttontest.cpp "")
/*
Copyright (c) 2020 Laurent Montel <montel@kde.org>
This library is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published by
the Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
*/
#include "loadtoolbuttontest.h"
#include "loadtoolbutton.h"
#include <QTest>
QTEST_MAIN(LoadToolButtonTest)
LoadToolButtonTest::LoadToolButtonTest(QObject *parent)
: QObject(parent)
{
}
void LoadToolButtonTest::shouldHaveDefaultValues()
{
LoadToolButton w;
QVERIFY(w.menu());
//TODO
}
/*
Copyright (c) 2020 Laurent Montel <montel@kde.org>
This library is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published by
the Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
*/
#ifndef LOADTOOLBUTTONTEST_H
#define LOADTOOLBUTTONTEST_H
#include <QObject>
class LoadToolButtonTest : public QObject
{
Q_OBJECT
public:
explicit LoadToolButtonTest(QObject *parent = nullptr);
~LoadToolButtonTest() override = default;
private Q_SLOTS:
void shouldHaveDefaultValues();
};
#endif // LOADTOOLBUTTONTEST_H
......@@ -27,6 +27,7 @@ set(kdebugsettings_LIB_SRCS
kdeapplicationtreelistwidget.cpp
categorywarning.cpp
loadtoolbutton.cpp
savetoolbutton.cpp
${kdebugsettings_debug_SRCS}
)
......
/*
Copyright (c) 2020 Laurent Montel <montel@kde.org>
This library is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published by
the Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
*/
#include "savetoolbutton.h"
SaveToolButton::SaveToolButton(QWidget *parent)
: QToolButton(parent)
{
//TODO
}
SaveToolButton::~SaveToolButton()
{
}
/*
Copyright (c) 2020 Laurent Montel <montel@kde.org>
This library is free software; you can redistribute it and/or modify it
under the terms of the GNU Library General Public License as published by
the Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
License for more details.
You should have received a copy of the GNU Library General Public License
along with this library; see the file COPYING.LIB. If not, write to the
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
*/
#ifndef SAVETOOLBUTTON_H
#define SAVETOOLBUTTON_H
#include <QToolButton>
#include "libkdebugsettings_private_export.h"
class LIBKDEBUGSETTINGS_EXPORT_TEST_EXPORT SaveToolButton : public QToolButton
{
Q_OBJECT
public:
explicit SaveToolButton(QWidget *parent = nullptr);
~SaveToolButton() override;
};
#endif // SAVETOOLBUTTON_H
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment