Home / Function/ Test_App_Mount_RootPath_Nested() — fiber Function Reference

Test_App_Mount_RootPath_Nested() — fiber Function Reference

Architecture documentation for the Test_App_Mount_RootPath_Nested() function in mount_test.go from the fiber codebase.

Entity Profile

Dependency Diagram

graph TD
  3f2efef9_e7b3_a809_9026_3e8501060875["Test_App_Mount_RootPath_Nested()"]
  dbd7cc10_1955_3f67_b103_5ae841223af0["mount_test.go"]
  3f2efef9_e7b3_a809_9026_3e8501060875 -->|defined in| dbd7cc10_1955_3f67_b103_5ae841223af0
  style 3f2efef9_e7b3_a809_9026_3e8501060875 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

mount_test.go lines 33–51

func Test_App_Mount_RootPath_Nested(t *testing.T) {
	t.Parallel()
	app := New()
	dynamic := New()
	apiserver := New()

	apiroutes := apiserver.Group("/v1")
	apiroutes.Get("/home", func(c Ctx) error {
		return c.SendString("home")
	})

	dynamic.Use("/api", apiserver)
	app.Use("/", dynamic)

	resp, err := app.Test(httptest.NewRequest(MethodGet, "/api/v1/home", http.NoBody))
	require.NoError(t, err, "app.Test(req)")
	require.Equal(t, 200, resp.StatusCode, "Status code")
	require.Equal(t, uint32(2), app.handlersCount)
}

Domain

Subdomains

Defined In

Frequently Asked Questions

What does Test_App_Mount_RootPath_Nested() do?
Test_App_Mount_RootPath_Nested() is a function in the fiber codebase, defined in mount_test.go.
Where is Test_App_Mount_RootPath_Nested() defined?
Test_App_Mount_RootPath_Nested() is defined in mount_test.go at line 33.

Analyze Your Own Codebase

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

Try Supermodel Free