test(ha-config-bootstrap): add failing startup validation tests (task 2.1)
RED-phase tests for 4 startup validation functions — all fail at link time because the functions under test do not exist yet: - validate_peer_count: even N>1 returns -EINVAL, odd N returns 0 - validate_cert_files: missing cert/key returns -ENOENT with full path in err_buf output param (asserted via strstr) - validate_vcpus: vcpus<=0 returns -EINVAL, positive returns 0 - validate_startup_config: vcpus key in config returns 0 (not fatal) and writes deprecation text into warn_buf (asserted via strstr)
This commit is contained in:
parent
560d8fa1c8
commit
bfa41eb135
4 changed files with 248 additions and 1 deletions
|
|
@ -34,6 +34,7 @@ extern void test_p3_manual_failover(void);
|
|||
extern void test_ctrl_metrics(void);
|
||||
extern void test_config_repl(void);
|
||||
extern void test_worker_join(void);
|
||||
extern void test_ha_startup(void);
|
||||
|
||||
void setUp(void) { return; }
|
||||
|
||||
|
|
@ -137,6 +138,7 @@ int main(int argc, char* argv[])
|
|||
TEST(test_ctrl_metrics);
|
||||
TEST(test_config_repl);
|
||||
TEST(test_worker_join);
|
||||
TEST(test_ha_startup);
|
||||
|
||||
return UNITY_END();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue