mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-20 00:51:42 +00:00
[hal] Rename PowerDistributionPanel to PowerDistribution (#3466)
Makes HAL more generic for the PDP, to enable the Rev PDH in the future.
This commit is contained in:
@@ -4,9 +4,9 @@
|
||||
|
||||
#include "gtest/gtest.h"
|
||||
#include "hal/HAL.h"
|
||||
#include "hal/PDP.h"
|
||||
#include "hal/PowerDistribution.h"
|
||||
#include "hal/handles/HandlesInternal.h"
|
||||
#include "hal/simulation/PDPData.h"
|
||||
#include "hal/simulation/PowerDistributionData.h"
|
||||
|
||||
namespace hal {
|
||||
|
||||
@@ -23,7 +23,7 @@ TEST(PdpSimTests, TestPdpInitialization) {
|
||||
const int INDEX_TO_TEST = 1;
|
||||
|
||||
int callbackParam = 0;
|
||||
int callbackId = HALSIM_RegisterPDPInitializedCallback(
|
||||
int callbackId = HALSIM_RegisterPowerDistributionInitializedCallback(
|
||||
INDEX_TO_TEST, &TestPdpInitializationCallback, &callbackParam, false);
|
||||
ASSERT_TRUE(0 != callbackId);
|
||||
|
||||
@@ -31,7 +31,8 @@ TEST(PdpSimTests, TestPdpInitialization) {
|
||||
|
||||
// Use out of range index
|
||||
gTestPdpCallbackName = "Unset";
|
||||
HAL_InitializePDP(INDEX_TO_TEST, &status);
|
||||
HAL_InitializePowerDistribution(INDEX_TO_TEST,
|
||||
HAL_PowerDistributionType_kCTRE, &status);
|
||||
EXPECT_EQ(0, status);
|
||||
EXPECT_STREQ("Initialized", gTestPdpCallbackName.c_str());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user