feat(daemon): FireEvent + event name resolution + in-process gRPC tests

- name_index: add resolve_event(name) -> CEID (unit-tested).
- equipment_service.hpp: extract the gRPC service + value/state conversion
  into a shared header; add FireEvent (optional per-fire variable values,
  then trigger the collection event by name). secs_gemd slims to main().
- test_daemon_service: real in-process gRPC integration test (client stub ->
  service -> EquipmentRuntime) proving SetVariables lands in the model,
  GetControlState reports the state, FireEvent and unknown-name paths behave.
  Separate secs_gemd_tests target (links grpc++/proto), gated on the daemon.

Core suite 459/459 (2799 assertions); daemon gRPC tests 15/15.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-10 18:07:12 +02:00
parent fc898f8410
commit cb85199f49
6 changed files with 230 additions and 64 deletions
+10
View File
@@ -21,3 +21,13 @@ TEST_CASE("resolve_variable maps config names to VIDs across SVIDs and DVIDs") {
CHECK_FALSE(gem::resolve_variable(m, "nonexistent").has_value());
CHECK_FALSE(gem::resolve_variable(m, "").has_value());
}
TEST_CASE("resolve_event maps collection-event names to CEIDs") {
gem::EquipmentDataModel m;
config::load_equipment(SECSGEM_DATA_DIR "/equipment.yaml", m);
CHECK(gem::resolve_event(m, "ControlStateChanged") == 100);
CHECK(gem::resolve_event(m, "ProcessStarted") == 300);
CHECK(gem::resolve_event(m, "ControlJobCompleted") == 401);
CHECK_FALSE(gem::resolve_event(m, "nonexistent").has_value());
}