sonic-telemetry
sonic-telemetry copied to clipboard
Add some new testcases to dialin and dialout mode
- In gnmi_server/server_test.go
Add getting queues tests and non-db data test. Since the non-db data could not be known in advance, so the return data is removed and it only compares with the path to verify.
- TestGnmiGET:
- Get COUNTERS:Ethernet68 Queues
- Get COUNTERS (use vendor alias):Ethernet68/1 Queues
- Get COUNTERS:Ethernet* Queues
- get non-db platform cpu
- TestGnmiSubscribe:
- poll query for platform/cpu
- TestGnmiGET:
- In dialout/dialout_client/dialout_client_test.go
Add periodic report type test. The non-db response is verified by path. Therefore, I add a new function to compare the path.
- DialOut to first collector in periodic mode (COUNTERS_PORT_NAME_MAP)
- DialOut to first collector in periodic mode (COUNTERS/Ethernet*)
- DialOut to second collector in periodic mode upon failure of first collector (COUNTERS/Ethernet68/Queues)
- DialOut to second collector in periodic mode upon failure of first collector (platform/cpu)
@hui-ma hi, could you please help to review