Documentation
¶
Overview ¶
containers unit tests
Index ¶
- Variables
- func HandleBulkDeleteSuccessfully(t *testing.T, fakeServer th.FakeServer)
- func HandleCreateContainerSuccessfully(t *testing.T, fakeServer th.FakeServer)
- func HandleDeleteContainerSuccessfully(t *testing.T, fakeServer th.FakeServer, options ...option)
- func HandleGetContainerSuccessfully(t *testing.T, fakeServer th.FakeServer, options ...option)
- func HandleListContainerInfoSuccessfully(t *testing.T, fakeServer th.FakeServer)
- func HandleListZeroContainerNames204(t *testing.T, fakeServer th.FakeServer)
- func HandleUpdateContainerSuccessfully(t *testing.T, fakeServer th.FakeServer, options ...option)
- func HandleUpdateContainerVersioningOff(t *testing.T, fakeServer th.FakeServer, options ...option)
- func HandleUpdateContainerVersioningOn(t *testing.T, fakeServer th.FakeServer, options ...option)
- func WithPath(s string) option
Constants ¶
This section is empty.
Variables ¶
var ExpectedListInfo = []containers.Container{
{
Count: 0,
Bytes: 0,
Name: "janeausten",
},
{
Count: 1,
Bytes: 14,
Name: "marktwain",
},
}
ExpectedListInfo is the result expected from a call to `List` when full info is requested.
var ExpectedListNames = []string{"janeausten", "marktwain"}
ExpectedListNames is the result expected from a call to `List` when just container names are requested.
Functions ¶
func HandleBulkDeleteSuccessfully ¶
func HandleBulkDeleteSuccessfully(t *testing.T, fakeServer th.FakeServer)
HandleBulkDeleteSuccessfully creates an HTTP handler at `/` on the test handler mux that responds with a `Delete` response.
func HandleCreateContainerSuccessfully ¶
func HandleCreateContainerSuccessfully(t *testing.T, fakeServer th.FakeServer)
HandleCreateContainerSuccessfully creates an HTTP handler at `/testContainer` on the test handler mux that responds with a `Create` response.
func HandleDeleteContainerSuccessfully ¶
func HandleDeleteContainerSuccessfully(t *testing.T, fakeServer th.FakeServer, options ...option)
HandleDeleteContainerSuccessfully creates an HTTP handler at `/testContainer` on the test handler mux that responds with a `Delete` response.
func HandleGetContainerSuccessfully ¶
func HandleGetContainerSuccessfully(t *testing.T, fakeServer th.FakeServer, options ...option)
HandleGetContainerSuccessfully creates an HTTP handler at `/testContainer` on the test handler mux that responds with a `Get` response.
func HandleListContainerInfoSuccessfully ¶
func HandleListContainerInfoSuccessfully(t *testing.T, fakeServer th.FakeServer)
HandleListContainerInfoSuccessfully creates an HTTP handler at `/` on the test handler mux that responds with a `List` response when full info is requested.
func HandleListZeroContainerNames204 ¶
func HandleListZeroContainerNames204(t *testing.T, fakeServer th.FakeServer)
HandleListZeroContainerNames204 creates an HTTP handler at `/` on the test handler mux that responds with "204 No Content" when container names are requested. This happens on some, but not all, objectstorage instances. This case is peculiar in that the server sends no `content-type` header.
func HandleUpdateContainerSuccessfully ¶
func HandleUpdateContainerSuccessfully(t *testing.T, fakeServer th.FakeServer, options ...option)
HandleUpdateContainerSuccessfully creates an HTTP handler at `/testContainer` on the test handler mux that responds with a `Update` response.
func HandleUpdateContainerVersioningOff ¶
func HandleUpdateContainerVersioningOff(t *testing.T, fakeServer th.FakeServer, options ...option)
HandleUpdateContainerVersioningOff creates an HTTP handler at `/testVersioning` on the test handler mux that responds with a `Update` response.
func HandleUpdateContainerVersioningOn ¶
func HandleUpdateContainerVersioningOn(t *testing.T, fakeServer th.FakeServer, options ...option)
HandleUpdateContainerVersioningOn creates an HTTP handler at `/testVersioning` on the test handler mux that responds with a `Update` response.
Types ¶
This section is empty.