Home / Function/ TestLoadHTMLFilesDebugMode() — gin Function Reference

TestLoadHTMLFilesDebugMode() — gin Function Reference

Architecture documentation for the TestLoadHTMLFilesDebugMode() function in gin_test.go from the gin codebase.

Entity Profile

Dependency Diagram

graph TD
  4d98e42c_a6ed_1c7d_2a89_4ff005628acf["TestLoadHTMLFilesDebugMode()"]
  936be97e_cadf_7cb7_50da_f99734bf8011["setupHTMLFiles()"]
  4d98e42c_a6ed_1c7d_2a89_4ff005628acf -->|calls| 936be97e_cadf_7cb7_50da_f99734bf8011
  style 4d98e42c_a6ed_1c7d_2a89_4ff005628acf fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

gin_test.go lines 241–259

func TestLoadHTMLFilesDebugMode(t *testing.T) {
	ts := setupHTMLFiles(
		t,
		DebugMode,
		false,
		func(router *Engine) {
			router.LoadHTMLFiles("./testdata/template/hello.tmpl", "./testdata/template/raw.tmpl")
		},
	)
	defer ts.Close()

	res, err := http.Get(ts.URL + "/test")
	if err != nil {
		t.Error(err)
	}

	resp, _ := io.ReadAll(res.Body)
	assert.Equal(t, "<h1>Hello world</h1>", string(resp))
}

Domain

Subdomains

Frequently Asked Questions

What does TestLoadHTMLFilesDebugMode() do?
TestLoadHTMLFilesDebugMode() is a function in the gin codebase.
What does TestLoadHTMLFilesDebugMode() call?
TestLoadHTMLFilesDebugMode() calls 1 function(s): setupHTMLFiles.

Analyze Your Own Codebase

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

Try Supermodel Free