aboutsummaryrefslogtreecommitdiff
path: root/test/health_reload_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'test/health_reload_test.go')
-rw-r--r--test/health_reload_test.go49
1 files changed, 49 insertions, 0 deletions
diff --git a/test/health_reload_test.go b/test/health_reload_test.go
new file mode 100644
index 000000000..66e701532
--- /dev/null
+++ b/test/health_reload_test.go
@@ -0,0 +1,49 @@
+package test
+
+import (
+ "io/ioutil"
+ "log"
+ "net/http"
+ "testing"
+)
+
+func TestHealthReload(t *testing.T) {
+ log.SetOutput(ioutil.Discard)
+
+ // Corefile with for example without proxy section.
+ corefile := `example.org:0 {
+ health localhost:35080
+}
+`
+ i, err := CoreDNSServer(corefile)
+ if err != nil {
+ t.Fatalf("Could not get CoreDNS serving instance: %s", err)
+ }
+
+ resp, err := http.Get("http://localhost:35080/health")
+ if err != nil {
+ t.Fatalf("Could not get health: %s", err)
+ }
+ body, err := ioutil.ReadAll(resp.Body)
+ if x := string(body); x != "OK" {
+ t.Fatalf("Expect OK, got %s", x)
+ }
+ resp.Body.Close()
+
+ i, err = i.Restart(NewInput(corefile))
+ if err != nil {
+ t.Fatalf("Could not restart CoreDNS serving instance: %s", err)
+ }
+
+ defer i.Stop()
+
+ resp, err = http.Get("http://localhost:35080/health")
+ if err != nil {
+ t.Fatalf("Could not get health: %s", err)
+ }
+ body, err = ioutil.ReadAll(resp.Body)
+ if x := string(body); x != "OK" {
+ t.Fatalf("Expect OK, got %s", x)
+ }
+ resp.Body.Close()
+}
arred/new-http'>jarred/new-http Unnamed repository; edit this file 'description' to name the repository.
aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js/modules/BunObjectModule.cpp (unfollow)
AgeCommit message (Expand)AuthorFilesLines
2023-09-13chore(docs): include missing links to Node.js APIs (#5281)Gravatar Steven 1-2/+2
2023-09-13docs(guide): fix expect assertion example in guide for `spyOn` (#5294)Gravatar wing 1-1/+1
2023-09-13add uninstall instructions (#5311)Gravatar Andrew Brown 1-0/+24
2023-09-13docs: update lockfile diff instructions (#5275)Gravatar Guilherme J. Tramontina 1-3/+7
2023-09-13fix(node/fetch): Make data URL fetch consistent with node (#5126)Gravatar David Hewitt 2-7/+37
2023-09-13avoid inserting extraneous"accept-encoding" header (#5057)Gravatar iidebyo 2-1/+22
2023-09-13docs(runtime): fix plugins loader extensions typo (#5250)Gravatar Zong 1-1/+1
2023-09-13chore: make comment grammatically correct (#5140)Gravatar Gareth Jones 1-1/+1
2023-09-13Add informative message on 'bun create react' (#5248)Gravatar Colin McDonnell 1-0/+22
2023-09-13docs(runtime): fix jsx FragmentFactory output example (#5243)Gravatar Zong 1-1/+1
2023-09-13file.exists() needs to be awaited to get the value (#5061)Gravatar amt8u 1-1/+1
2023-09-13Update discordjs.md (#5227)Gravatar Antonin CLAUZIER 1-1/+1
2023-09-13decode regex if needed (#5167)Gravatar Dylan Conway 5-126/+167
2023-09-13Correct the configuration file names. (#5234)Gravatar Nathan Hammond 2-2/+2
2023-09-12Update tsconfig.json for bun initGravatar Colin McDonnell 1-1/+1
2023-09-12js/node/stream.js: call write() callback when encoding is not provided (#4841)Gravatar cfal 2-3/+7
2023-09-12docs: Made bun-types install as dev dependency in example (#5120)Gravatar Gordon Goldbach 1-1/+1
2023-09-12Various docs (#5201)Gravatar Colin McDonnell 4-4/+147
2023-09-12Use git's --global flag for lockfile diffs instead of manually modifying conf...Gravatar Southpaw 1-17/+7
2023-09-12docs: fix typo in import.meta.resolve (#5146)Gravatar Jonathan Neal 1-1/+1
2023-09-12Update hot.md (#4990)Gravatar Nazeel 1-1/+1
2023-09-12Update simple.md (#4997)Gravatar Tom Redman 1-1/+1
2023-09-12fix typo and grammar errors (#5046)Gravatar xnacly 1-3/+3
2023-09-12clang and llvm on arch install v16, update to use v15 (#5069)Gravatar mi4uu 1-1/+10
2023-09-12Add missing full stop on nodejs-apis.md (#5072)Gravatar Diogo Goncalves 1-5/+5
2023-09-12udate README.md (#5127)Gravatar Toby 1-1/+1
2023-09-12docs: fix typos (#5151)Gravatar Samuel Rigaud 17-18/+18
2023-09-12fix lifecycle docu (#5159)Gravatar Thomas Rupprecht 1-4/+4
2023-09-12Clean up Modules docGravatar Colin McDonnell 1-66/+73