towerops/test/towerops/snmp
Graham McIntire 3ca0834ef0 tests: raise coverage to 70% via helper promotion + new unit/property tests
Promoted pure presentation and utility helpers from `defp` to `def @doc false`
across ~20 LiveViews, Oban workers, and sync modules so they're reachable from
unit tests. Refactored several `cond` blocks into idiomatic function heads with
guards. Added ~250 new test cases in new files under test/towerops and
test/towerops_web, including DB-backed tests for CnMaestro.Sync and
AlertNotificationWorker, and removed dead LiveView tab components and
CapacityLive (no callers anywhere in lib/test).

Configured mix.exs test_coverage.ignore_modules to exclude vendored third-party
code (SnmpKit, protobuf-generated Towerops.Agent.*, Absinthe GraphQL types,
Phoenix HTML modules, Inspect protocol impls) from coverage calculations —
these are not our project code.

Coverage: 66.93% → 70.09%. Full suite: 10,127 tests, 0 failures.
2026-04-24 09:49:06 -05:00
..
adapters fix: agent discovery and polling accuracy improvements 2026-02-11 15:58:31 -06:00
discovery feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
profiles fix snmp handling to be more like librenms (#190) 2026-03-27 13:37:27 -05:00
wireless_client_discovery tests: raise coverage to 70% via helper promotion + new unit/property tests 2026-04-24 09:49:06 -05:00
arp_discovery_test.exs arp 2026-01-23 08:40:57 -06:00
batch_insert_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
client_test.exs feat: implement batched SNMP GET for multi-OID requests (#183) 2026-03-26 16:37:34 -05:00
deferred_discovery_test.exs perf(tests): aggressive timeout and delay reductions 2026-03-06 08:28:18 -06:00
discovery_test.exs feat: implement batched SNMP GET for multi-OID requests (#183) 2026-03-26 16:37:34 -05:00
entity_physical_context_test.exs feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
entity_physical_reading_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
entity_physical_test.exs feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
ip_address_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
mac_address_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
mac_discovery_test.exs mac discovery 2026-01-23 09:22:08 -06:00
memory_pool_test.exs refactor/dry-improvements (#202) 2026-03-28 10:56:34 -05:00
mempool_reading_test.exs feat: implement mempools (memory pools) feature for SNMP monitoring (#184) 2026-03-26 17:07:43 -05:00
mempool_test.exs feat: implement mempools (memory pools) feature for SNMP monitoring (#184) 2026-03-26 17:07:43 -05:00
mib_parser_test.exs more tests 2026-01-20 16:38:53 -06:00
mib_translator_test.exs Merge remote-tracking branch 'origin/main' into feature/preseem-integration 2026-02-13 09:11:45 -06:00
mib_validation_test.exs add MIB-based validation and generic profile tests 2026-01-08 08:57:21 -06:00
neighbor_cleanup_worker_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
neighbor_discovery_test.exs fix/critical-logic-and-memory-bugs (#159) 2026-03-25 09:50:21 -05:00
neighbor_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
physical_entity_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
poller_test.exs perf(tests): remove/reduce Process.sleep calls for faster tests 2026-03-06 07:57:30 -06:00
printer_supply_context_test.exs feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
printer_supply_test.exs feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
processor_reading_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
processor_test.exs sanitize snmp data and fix some cpu things 2026-01-22 16:53:01 -06:00
sanitizer_test.exs sanitize snmp data and fix some cpu things 2026-01-22 16:53:01 -06:00
sensor_change_detector_test.exs fix: display count sensor values as integers instead of floats 2026-03-06 15:03:30 -06:00
state_sensor_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
storage_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
transceiver_context_test.exs feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
transceiver_reading_test.exs feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
transceiver_test.exs feature/entity-physical-inventory (#187) 2026-03-27 10:48:50 -05:00
vlan_test.exs make devices site optional and many test fix 2026-02-04 15:05:42 -06:00
wireless_client_discovery_test.exs tests: raise coverage to 70% via helper promotion + new unit/property tests 2026-04-24 09:49:06 -05:00