MCPcopy Create free account
hub / github.com/github/gh-aw / TestComputeFirewallDiff_Run1Nil

Function TestComputeFirewallDiff_Run1Nil

pkg/cli/audit_diff_test.go:188–199  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

186}
187
188func TestComputeFirewallDiff_Run1Nil(t *testing.T) {
189 run2 := &FirewallAnalysis{
190 RequestsByDomain: map[string]DomainRequestStats{
191 "api.github.com:443": {Allowed: 5, Blocked: 0},
192 },
193 }
194
195 diff := computeFirewallDiff(100, 200, nil, run2)
196
197 assert.Len(t, diff.NewDomains, 1, "All run2 domains should be new")
198 assert.Equal(t, "api.github.com:443", diff.NewDomains[0].Domain, "New domain should be api.github.com")
199}
200
201func TestComputeFirewallDiff_Run2Nil(t *testing.T) {
202 run1 := &FirewallAnalysis{

Callers

nothing calls this directly

Calls 1

computeFirewallDiffFunction · 0.85

Tested by

no test coverage detected