summaryrefslogtreecommitdiff
path: root/gemini/response_test.go
diff options
context:
space:
mode:
authortjpcc <tjp@ctrl-c.club>2023-05-01 07:56:25 -0600
committertjpcc <tjp@ctrl-c.club>2023-05-01 07:56:25 -0600
commit9a2da81b11ad0064cca24ce7974827d032309369 (patch)
tree4313224dc089208423e78bffc3ec50833e35bcea /gemini/response_test.go
parent21e2758145d100d74013060f7090d84679cae683 (diff)
name change gus -> sliderule
Diffstat (limited to 'gemini/response_test.go')
-rw-r--r--gemini/response_test.go20
1 files changed, 10 insertions, 10 deletions
diff --git a/gemini/response_test.go b/gemini/response_test.go
index 9287d71..00166dd 100644
--- a/gemini/response_test.go
+++ b/gemini/response_test.go
@@ -6,15 +6,15 @@ import (
"io"
"testing"
- "tildegit.org/tjp/gus"
- "tildegit.org/tjp/gus/gemini"
+ sr "tildegit.org/tjp/sliderule"
+ "tildegit.org/tjp/sliderule/gemini"
)
func TestBuildResponses(t *testing.T) {
table := []struct {
name string
- response *gus.Response
- status gus.Status
+ response *sr.Response
+ status sr.Status
meta string
body string
}{
@@ -154,7 +154,7 @@ func TestBuildResponses(t *testing.T) {
func TestParseResponses(t *testing.T) {
table := []struct {
input string
- status gus.Status
+ status sr.Status
meta string
body string
err error
@@ -233,7 +233,7 @@ func TestParseResponses(t *testing.T) {
func TestResponseClose(t *testing.T) {
body := &rdCloser{Buffer: bytes.NewBufferString("the body here")}
- resp := &gus.Response{
+ resp := &sr.Response{
Status: gemini.StatusSuccess,
Meta: "text/gemini",
Body: body,
@@ -247,7 +247,7 @@ func TestResponseClose(t *testing.T) {
t.Error("response body was not closed by response.Close()")
}
- resp = &gus.Response{
+ resp = &sr.Response{
Status: gemini.StatusInput,
Meta: "give me more",
}
@@ -270,8 +270,8 @@ func (rc *rdCloser) Close() error {
func TestResponseWriteTo(t *testing.T) {
// invariant under test: WriteTo() sends the same bytes as Read()
- clone := func(resp *gus.Response) *gus.Response {
- other := &gus.Response{
+ clone := func(resp *sr.Response) *sr.Response {
+ other := &sr.Response{
Status: resp.Status,
Meta: resp.Meta,
}
@@ -297,7 +297,7 @@ func TestResponseWriteTo(t *testing.T) {
table := []struct {
name string
- response *gus.Response
+ response *sr.Response
}{
{
name: "simple success",