Home / Function/ TestPathCleanMallocs() — gin Function Reference

TestPathCleanMallocs() — gin Function Reference

Architecture documentation for the TestPathCleanMallocs() function in path_test.go from the gin codebase.

Entity Profile

Dependency Diagram

graph TD
  c5e30b8d_6a8c_958e_d8bc_70a1a400037f["TestPathCleanMallocs()"]
  b533967c_d510_b36e_3d17_b3b896fbdfe2["path_test.go"]
  c5e30b8d_6a8c_958e_d8bc_70a1a400037f -->|defined in| b533967c_d510_b36e_3d17_b3b896fbdfe2
  style c5e30b8d_6a8c_958e_d8bc_70a1a400037f fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

path_test.go lines 79–92

func TestPathCleanMallocs(t *testing.T) {
	if testing.Short() {
		t.Skip("skipping malloc count in short mode")
	}

	if runtime.GOMAXPROCS(0) > 1 {
		t.Skip("skipping malloc count; GOMAXPROCS>1")
	}

	for _, test := range cleanTests {
		allocs := testing.AllocsPerRun(100, func() { cleanPath(test.result) })
		assert.InDelta(t, 0, allocs, 0.01)
	}
}

Domain

Subdomains

Defined In

Frequently Asked Questions

What does TestPathCleanMallocs() do?
TestPathCleanMallocs() is a function in the gin codebase, defined in path_test.go.
Where is TestPathCleanMallocs() defined?
TestPathCleanMallocs() is defined in path_test.go at line 79.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free