mirror of
https://github.com/Armored-Dragon/overte.git
synced 2025-03-11 16:13:16 +01:00
WIP - add results to runs.
This commit is contained in:
parent
66391c2d64
commit
2a6bc8bd3e
4 changed files with 435 additions and 0 deletions
|
@ -926,6 +926,7 @@ void TestRailInterface::createTestRailRun(const QString& outputDirectory) {
|
|||
|
||||
|
||||
void TestRailInterface::updateTestRailRunResults(const QString& testResults, const QString& tempDirectory) {
|
||||
// Extract test failures from zipped folder
|
||||
QString tempSubDirectory = tempDirectory + "/" + tempName;
|
||||
QDir dir = tempSubDirectory;
|
||||
dir.mkdir(tempSubDirectory);
|
||||
|
|
104
tools/auto-tester/src/ui/TestRailResultsSelectorWindow.cpp
Normal file
104
tools/auto-tester/src/ui/TestRailResultsSelectorWindow.cpp
Normal file
|
@ -0,0 +1,104 @@
|
|||
//
|
||||
// TestRailResultsSelectorWindow.cpp
|
||||
//
|
||||
// Created by Nissim Hadar on 2 Aug 2017.
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
#include "TestRailResultsSelectorWindow.h"
|
||||
|
||||
#include <QtCore/QFileInfo>
|
||||
|
||||
#include <cmath>
|
||||
|
||||
TestRailResultsSelectorWindow::TestRailResultsSelectorWindow(QWidget *parent) {
|
||||
setupUi(this);
|
||||
|
||||
projectIDLineEdit->setValidator(new QIntValidator(1, 999, this));
|
||||
}
|
||||
|
||||
|
||||
void TestRailResultsSelectorWindow::reset() {
|
||||
urlLineEdit->setDisabled(false);
|
||||
userLineEdit->setDisabled(false);
|
||||
passwordLineEdit->setDisabled(false);
|
||||
projectIDLineEdit->setDisabled(false);
|
||||
|
||||
OKButton->setDisabled(true);
|
||||
|
||||
releasesLabel->setDisabled(true);
|
||||
releasesComboBox->setDisabled(true);
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::on_acceptButton_clicked() {
|
||||
urlLineEdit->setDisabled(true);
|
||||
userLineEdit->setDisabled(true);
|
||||
passwordLineEdit->setDisabled(true);
|
||||
projectIDLineEdit->setDisabled(true);
|
||||
|
||||
OKButton->setDisabled(false);
|
||||
|
||||
releasesLabel->setDisabled(false);
|
||||
releasesComboBox->setDisabled(false);
|
||||
close();
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::on_OKButton_clicked() {
|
||||
userCancelled = false;
|
||||
close();
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::on_cancelButton_clicked() {
|
||||
userCancelled = true;
|
||||
close();
|
||||
}
|
||||
|
||||
bool TestRailResultsSelectorWindow::getUserCancelled() {
|
||||
return userCancelled;
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::setURL(const QString& user) {
|
||||
urlLineEdit->setText(user);
|
||||
}
|
||||
|
||||
QString TestRailResultsSelectorWindow::getURL() {
|
||||
return urlLineEdit->text();
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::setUser(const QString& user) {
|
||||
userLineEdit->setText(user);
|
||||
}
|
||||
|
||||
QString TestRailResultsSelectorWindow::getUser() {
|
||||
return userLineEdit->text();
|
||||
}
|
||||
|
||||
QString TestRailResultsSelectorWindow::getPassword() {
|
||||
return passwordLineEdit->text();
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::setProjectID(const int project) {
|
||||
projectIDLineEdit->setText(QString::number(project));
|
||||
}
|
||||
|
||||
int TestRailResultsSelectorWindow::getProjectID() {
|
||||
return projectIDLineEdit->text().toInt();
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::setSuiteID(const int project) {
|
||||
suiteIDLineEdit->setText(QString::number(project));
|
||||
}
|
||||
|
||||
int TestRailResultsSelectorWindow::getSuiteID() {
|
||||
return suiteIDLineEdit->text().toInt();
|
||||
}
|
||||
|
||||
void TestRailResultsSelectorWindow::updateReleasesComboBoxData(QStringList data) {
|
||||
releasesComboBox->insertItems(0, data);
|
||||
}
|
||||
|
||||
int TestRailResultsSelectorWindow::getReleaseID() {
|
||||
return releasesComboBox->currentIndex();
|
||||
}
|
50
tools/auto-tester/src/ui/TestRailResultsSelectorWindow.h
Normal file
50
tools/auto-tester/src/ui/TestRailResultsSelectorWindow.h
Normal file
|
@ -0,0 +1,50 @@
|
|||
//
|
||||
// TestRailResultsSelectorWindow.h
|
||||
//
|
||||
// Created by Nissim Hadar on 2 Aug 2017.
|
||||
// Copyright 2013 High Fidelity, Inc.
|
||||
//
|
||||
// Distributed under the Apache License, Version 2.0.
|
||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||
//
|
||||
#ifndef hifi_TestRailResultsSelectorWindow_h
|
||||
#define hifi_TestRailResultsSelectorWindow_h
|
||||
|
||||
#include "ui_TestRailResultsSelectorWindow.h"
|
||||
|
||||
class TestRailResultsSelectorWindow : public QDialog, public Ui::TestRailResultsSelectorWindow {
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
TestRailResultsSelectorWindow(QWidget* parent = Q_NULLPTR);
|
||||
|
||||
void reset();
|
||||
|
||||
bool getUserCancelled();
|
||||
|
||||
void setURL(const QString& user);
|
||||
QString getURL();
|
||||
|
||||
void setUser(const QString& user);
|
||||
QString getUser();
|
||||
|
||||
QString getPassword();
|
||||
|
||||
void setProjectID(const int project);
|
||||
int getProjectID();
|
||||
|
||||
void setSuiteID(const int project);
|
||||
int getSuiteID();
|
||||
|
||||
bool userCancelled{ false };
|
||||
|
||||
void updateReleasesComboBoxData(QStringList data);
|
||||
int getReleaseID();
|
||||
|
||||
private slots:
|
||||
void on_acceptButton_clicked();
|
||||
void on_OKButton_clicked();
|
||||
void on_cancelButton_clicked();
|
||||
};
|
||||
|
||||
#endif
|
280
tools/auto-tester/src/ui/TestRailResultsSelectorWindow.ui
Normal file
280
tools/auto-tester/src/ui/TestRailResultsSelectorWindow.ui
Normal file
|
@ -0,0 +1,280 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>TestRailResultsSelectorWindow</class>
|
||||
<widget class="QDialog" name="TestRailResultsSelectorWindow">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>489</width>
|
||||
<height>474</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>TestRail Test Case Selector Window</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="errorLabel">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>30</x>
|
||||
<y>850</y>
|
||||
<width>500</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>12</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>similarity</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>70</x>
|
||||
<y>125</y>
|
||||
<width>121</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>10</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>TestRail Password</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="label_2">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>70</x>
|
||||
<y>25</y>
|
||||
<width>121</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>10</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>TestRail URL</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="OKButton">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>120</x>
|
||||
<y>420</y>
|
||||
<width>93</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="cancelButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>280</x>
|
||||
<y>420</y>
|
||||
<width>93</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="passwordLineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>200</x>
|
||||
<y>120</y>
|
||||
<width>231</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Password</enum>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="label_3">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>70</x>
|
||||
<y>75</y>
|
||||
<width>121</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>10</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>TestRail User</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="projectIDLineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>200</x>
|
||||
<y>170</y>
|
||||
<width>231</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Normal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="label_4">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>70</x>
|
||||
<y>175</y>
|
||||
<width>121</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>10</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>TestRail Project ID</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="acceptButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>200</x>
|
||||
<y>270</y>
|
||||
<width>231</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Accept</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="releasesComboBox">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>270</x>
|
||||
<y>350</y>
|
||||
<width>161</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="releasesLabel">
|
||||
<property name="enabled">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>80</x>
|
||||
<y>350</y>
|
||||
<width>181</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>10</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>TestRail Added for release</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="urlLineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>200</x>
|
||||
<y>20</y>
|
||||
<width>231</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Normal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="userLineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>200</x>
|
||||
<y>70</y>
|
||||
<width>231</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Normal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="suiteIDLineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>200</x>
|
||||
<y>215</y>
|
||||
<width>231</width>
|
||||
<height>24</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="echoMode">
|
||||
<enum>QLineEdit::Normal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="label_5">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>70</x>
|
||||
<y>220</y>
|
||||
<width>121</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>10</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>TestRail Suite ID</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<layoutdefault spacing="6" margin="11"/>
|
||||
<tabstops>
|
||||
<tabstop>urlLineEdit</tabstop>
|
||||
<tabstop>userLineEdit</tabstop>
|
||||
<tabstop>passwordLineEdit</tabstop>
|
||||
<tabstop>projectIDLineEdit</tabstop>
|
||||
<tabstop>suiteIDLineEdit</tabstop>
|
||||
<tabstop>acceptButton</tabstop>
|
||||
<tabstop>releasesComboBox</tabstop>
|
||||
<tabstop>OKButton</tabstop>
|
||||
<tabstop>cancelButton</tabstop>
|
||||
</tabstops>
|
||||
<resources/>
|
||||
<connections/>
|
||||
</ui>
|
Loading…
Reference in a new issue