Hotwheels-Cluster 1.2
Creation of Cluster APP for SEA:ME project.
 
Loading...
Searching...
No Matches
test_int_CanBusManager.cpp File Reference

Integration tests for the CanBusManager class. More...

#include <QCoreApplication>
#include <QDebug>
#include <QSignalSpy>
#include "CanBusManager.hpp"
#include "MCP2515Controller.hpp"
#include <gtest/gtest.h>

Go to the source code of this file.

Data Structures

class  CanBusManagerTest
 Class to test the integration between the CanBusManager and the MCP2515 controller. More...
 

Functions

 TEST_F (CanBusManagerTest, ForwardSpeedDataFromMCP2515)
 Ensures that the CanBusManager forwards speed data from the MCP2515 controller.
 
 TEST_F (CanBusManagerTest, ForwardRpmDataFromMCP2515)
 Ensures that the CanBusManager forwards RPM data from the MCP2515 controller.
 
 TEST_F (CanBusManagerTest, InitializeCanBusManager)
 Ensures that the CanBusManager initializes successfully.
 
 TEST_F (CanBusManagerTest, ManagerCleanUpBehavior)
 Ensures that the CanBusManager cleans up properly.
 

Detailed Description

Integration tests for the CanBusManager class.

Version
0.1
Date
2025-02-12
Author
Michel Batista (@MicchelFAB)
Fรฉlix LE BIHAN (@Fle-bihh)
Ricardo Melo (@reomelo)
Tiago Pereira (@t-pereira06)

Definition in file test_int_CanBusManager.cpp.

Function Documentation

◆ TEST_F() [1/4]

TEST_F ( CanBusManagerTest ,
ForwardRpmDataFromMCP2515  )

Ensures that the CanBusManager forwards RPM data from the MCP2515 controller.

Test
๐Ÿ”„ Forward RPM Data

This test verifies that the CanBusManager forwards RPM data from the MCP2515 controller by emitting the rpmUpdated signal.

See also
CanBusManager::rpmUpdated

Definition at line 90 of file test_int_CanBusManager.cpp.

Here is the call graph for this function:

◆ TEST_F() [2/4]

TEST_F ( CanBusManagerTest ,
ForwardSpeedDataFromMCP2515  )

Ensures that the CanBusManager forwards speed data from the MCP2515 controller.

Test
๐Ÿš— Forward Speed Data

This test verifies that the CanBusManager forwards speed data from the MCP2515 controller by emitting the speedUpdated signal.

See also
CanBusManager::speedUpdated

Definition at line 70 of file test_int_CanBusManager.cpp.

Here is the call graph for this function:

◆ TEST_F() [3/4]

TEST_F ( CanBusManagerTest ,
InitializeCanBusManager  )

Ensures that the CanBusManager initializes successfully.

Test
๐Ÿš€ Initialization

This test verifies that the CanBusManager initializes successfully by calling the initialize() method.

See also
CanBusManager::initialize

Definition at line 109 of file test_int_CanBusManager.cpp.

◆ TEST_F() [4/4]

TEST_F ( CanBusManagerTest ,
ManagerCleanUpBehavior  )

Ensures that the CanBusManager cleans up properly.

Test
๐Ÿงน Manager Clean-Up Behavior

This test verifies that the CanBusManager cleans up properly by deleting the manager and checking if the thread was deleted.

Definition at line 122 of file test_int_CanBusManager.cpp.

Here is the call graph for this function: