mirror of
https://github.com/ProtonMail/proton-bridge.git
synced 2025-12-21 17:46:48 +00:00
feat(GODT-2239): introduce GoogleTest unit tests for bridgepp.
This commit is contained in:
@ -20,7 +20,7 @@
|
||||
#define BRIDGE_PP_TESTER_BRIDGE_UTILS_H
|
||||
|
||||
|
||||
#include <bridgepp/User/User.h>
|
||||
#include "User/User.h"
|
||||
|
||||
|
||||
namespace bridgepp {
|
||||
|
||||
@ -87,6 +87,14 @@ QString Exception::details() const noexcept {
|
||||
}
|
||||
|
||||
|
||||
//****************************************************************************************************************************************************
|
||||
/// \return The function that threw the exception.
|
||||
//****************************************************************************************************************************************************
|
||||
QString Exception::function() const noexcept {
|
||||
return function_;
|
||||
}
|
||||
|
||||
|
||||
//****************************************************************************************************************************************************
|
||||
/// \return The attachment for the exception.
|
||||
//****************************************************************************************************************************************************
|
||||
@ -109,4 +117,5 @@ QString Exception::detailedWhat() const {
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
} // namespace bridgepp
|
||||
|
||||
@ -42,6 +42,7 @@ public: // member functions
|
||||
QString qwhat() const noexcept; ///< Return the description of the exception as a QString
|
||||
const char *what() const noexcept override; ///< Return the description of the exception as C style string
|
||||
QString details() const noexcept; ///< Return the details for the exception
|
||||
QString function() const noexcept; ///< Return the function that threw the exception.
|
||||
QByteArray attachment() const noexcept; ///< Return the attachment for the exception.
|
||||
QString detailedWhat() const; ///< Return the detailed description of the message (i.e. including the function name and the details).
|
||||
|
||||
|
||||
@ -17,8 +17,8 @@
|
||||
|
||||
|
||||
#include "LogUtils.h"
|
||||
#include <bridgepp/BridgeUtils.h>
|
||||
#include <bridgepp/Exception/Exception.h>
|
||||
#include "../BridgeUtils.h"
|
||||
#include "../Exception/Exception.h"
|
||||
|
||||
|
||||
namespace bridgepp {
|
||||
|
||||
Reference in New Issue
Block a user