Home / Function/ Test_App_RegisterNetHTTPHandler() — fiber Function Reference

Test_App_RegisterNetHTTPHandler() — fiber Function Reference

Architecture documentation for the Test_App_RegisterNetHTTPHandler() function in app_test.go from the fiber codebase.

Entity Profile

Dependency Diagram

graph TD
  ac4abcaf_5d92_db9c_40db_5bb3a1d47adf["Test_App_RegisterNetHTTPHandler()"]
  e728fdd2_242f_706b_c1d2_041b3d6badb5["app_test.go"]
  ac4abcaf_5d92_db9c_40db_5bb3a1d47adf -->|defined in| e728fdd2_242f_706b_c1d2_041b3d6badb5
  style ac4abcaf_5d92_db9c_40db_5bb3a1d47adf fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

app_test.go lines 229–350

func Test_App_RegisterNetHTTPHandler(t *testing.T) {
	t.Parallel()

	tests := []struct {
		name       string
		register   func(app *App, path string, handler any)
		method     string
		expectBody bool
	}{
		{
			name: "Get",
			register: func(app *App, path string, handler any) {
				app.Get(path, handler)
			},
			method:     http.MethodGet,
			expectBody: true,
		},
		{
			name: "Head",
			register: func(app *App, path string, handler any) {
				app.Head(path, handler)
			},
			method: http.MethodHead,
		},
		{
			name: "Post",
			register: func(app *App, path string, handler any) {
				app.Post(path, handler)
			},
			method:     http.MethodPost,
			expectBody: true,
		},
		{
			name: "Put",
			register: func(app *App, path string, handler any) {
				app.Put(path, handler)
			},
			method:     http.MethodPut,
			expectBody: true,
		},
		{
			name: "Delete",
			register: func(app *App, path string, handler any) {
				app.Delete(path, handler)
			},
			method:     http.MethodDelete,
			expectBody: true,
		},
		{
			name: "Connect",
			register: func(app *App, path string, handler any) {
				app.Connect(path, handler)
			},
			method:     http.MethodConnect,
			expectBody: true,
		},
		{
			name: "Options",
			register: func(app *App, path string, handler any) {
				app.Options(path, handler)
			},
			method:     http.MethodOptions,
			expectBody: true,
		},
		{
			name: "Trace",
			register: func(app *App, path string, handler any) {
				app.Trace(path, handler)
			},
			method:     http.MethodTrace,
			expectBody: true,
		},
		{
			name: "Patch",
			register: func(app *App, path string, handler any) {
				app.Patch(path, handler)
			},
			method:     http.MethodPatch,
			expectBody: true,
		},
	}

Domain

Subdomains

Defined In

Frequently Asked Questions

What does Test_App_RegisterNetHTTPHandler() do?
Test_App_RegisterNetHTTPHandler() is a function in the fiber codebase, defined in app_test.go.
Where is Test_App_RegisterNetHTTPHandler() defined?
Test_App_RegisterNetHTTPHandler() is defined in app_test.go at line 229.

Analyze Your Own Codebase

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

Try Supermodel Free