(t *testing.T)
| 678 | } |
| 679 | |
| 680 | func TestEnableDumpAllToFile(t *testing.T) { |
| 681 | c := tc() |
| 682 | dumpFile := "tmp_test_dump_file" |
| 683 | c.EnableDumpAllToFile(tests.GetTestFilePath(dumpFile)) |
| 684 | resp, err := c.R().SetBody("test body").Post("/") |
| 685 | assertSuccess(t, resp, err) |
| 686 | dump := string(getTestFileContent(t, dumpFile)) |
| 687 | os.Remove(tests.GetTestFilePath(dumpFile)) |
| 688 | tests.AssertContains(t, dump, "user-agent", true) |
| 689 | tests.AssertContains(t, dump, "test body", true) |
| 690 | tests.AssertContains(t, dump, "date", true) |
| 691 | tests.AssertContains(t, dump, "testpost: text response", true) |
| 692 | } |
| 693 | |
| 694 | func TestEnableDumpAllAsync(t *testing.T) { |
| 695 | c := tc() |
nothing calls this directly
no test coverage detected
searching dependent graphs…