|
7 | 7 | "goji.io/pat"
|
8 | 8 | )
|
9 | 9 |
|
10 |
| -func TestGetThisServer(t *testing.T) { |
| 10 | +func TestGetCurrentServer(t *testing.T) { |
11 | 11 | responseJSON := `{
|
12 | 12 | "ID": 1,
|
13 | 13 | "Name": "Staging Testing",
|
@@ -37,17 +37,17 @@ func TestGetThisServer(t *testing.T) {
|
37 | 37 | w.Write([]byte(responseJSON))
|
38 | 38 | })
|
39 | 39 |
|
40 |
| - res, err := client.GetThisServer() |
| 40 | + res, err := client.GetCurrentServer() |
41 | 41 | if err != nil {
|
42 |
| - t.Fatalf("GetThisServer: %s", err.Error()) |
| 42 | + t.Fatalf("GetCurrentServer: %s", err.Error()) |
43 | 43 | }
|
44 | 44 |
|
45 | 45 | if res.Name != "Staging Testing" {
|
46 |
| - t.Fatalf("GetThisServer: wrong name!: %s", res.Name) |
| 46 | + t.Fatalf("GetCurrentServer: wrong name!: %s", res.Name) |
47 | 47 | }
|
48 | 48 | }
|
49 | 49 |
|
50 |
| -func TestEditThisServer(t *testing.T) { |
| 50 | +func TestEditCurrentServer(t *testing.T) { |
51 | 51 | responseJSON := `{
|
52 | 52 | "ID": 1,
|
53 | 53 | "Name": "Production Testing",
|
@@ -76,15 +76,15 @@ func TestEditThisServer(t *testing.T) {
|
76 | 76 | w.Write([]byte(responseJSON))
|
77 | 77 | })
|
78 | 78 |
|
79 |
| - res, err := client.EditThisServer(Server{ |
| 79 | + res, err := client.EditCurrentServer(Server{ |
80 | 80 | Name: "Production Testing",
|
81 | 81 | })
|
82 | 82 |
|
83 | 83 | if err != nil {
|
84 |
| - t.Fatalf("EditThisServer: %s", err.Error()) |
| 84 | + t.Fatalf("EditCurrentServer: %s", err.Error()) |
85 | 85 | }
|
86 | 86 |
|
87 | 87 | if res.Name != "Production Testing" {
|
88 |
| - t.Fatalf("EditThisServer: wrong name!: %s", res.Name) |
| 88 | + t.Fatalf("EditCurrentServer: wrong name!: %s", res.Name) |
89 | 89 | }
|
90 | 90 | }
|
0 commit comments