less hacky testing implementation

This commit is contained in:
rusefi 2020-09-03 22:52:29 -04:00
parent cd30652044
commit be49f46057
3 changed files with 4 additions and 4 deletions

View File

@ -12,11 +12,11 @@ public:
void init(bool usePwm, SimplePwm* pwm, OutputPin* outputPin, const ValueProvider3D* table, const gppwm_channel* config);
void update();
private:
float getOutput() const;
void setOutput(float result);
private:
// Store the current state so we can apply hysteresis
bool m_state = false;

View File

@ -18,7 +18,6 @@ public:
void showInfo(Logging* logger, float testRawValue) const override;
private:
// Steinhart-Hart coefficients
float m_a = 0;
float m_b = 0;

View File

@ -13,7 +13,8 @@
using ::testing::Return;
// This lets us inspect private state from unit tests
#define private public
// cool hack but probably should not be used, even conditional private/public compilation is more obvious
//#define private public
/**
* These are usually used with ASSETR_NEAR(val1, val2, abs_error)