testing

package
v1.0.23-3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 9, 2020 License: Apache-2.0 Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

common extensions unit tests

Index

Constants

View Source
const GetOutput = `` /* 234-byte string literal not displayed */

GetOutput provides a single Extension result.

View Source
const ListOutput = `` /* 331-byte string literal not displayed */

ListOutput provides a single page of Extension results.

Variables

View Source
var ExpectedExtensions = []extensions.Extension{ListedExtension}

ExpectedExtensions is a slice containing the Extension that should be parsed from ListOutput.

View Source
var ListedExtension = extensions.Extension{
	Updated:     "2013-01-20T00:00:00-00:00",
	Name:        "Neutron Service Type Management",
	Links:       []interface{}{},
	Namespace:   "http://docs.openstack.org/ext/neutron/service-type/api/v1.0",
	Alias:       "service-type",
	Description: "API for retrieving service providers for Neutron advanced services",
}

ListedExtension is the Extension that should be parsed from ListOutput.

View Source
var SingleExtension = &extensions.Extension{
	Updated:     "2013-02-03T10:00:00-00:00",
	Name:        "agent",
	Links:       []interface{}{},
	Namespace:   "http://docs.openstack.org/ext/agent/api/v2.0",
	Alias:       "agent",
	Description: "The agent management extension.",
}

SingleExtension is the Extension that should be parsed from GetOutput.

Functions

func HandleGetExtensionSuccessfully

func HandleGetExtensionSuccessfully(t *testing.T)

HandleGetExtensionSuccessfully creates an HTTP handler at `/extensions/agent` that responds with a JSON payload corresponding to SingleExtension.

func HandleListExtensionsSuccessfully

func HandleListExtensionsSuccessfully(t *testing.T)

HandleListExtensionsSuccessfully creates an HTTP handler at `/extensions` on the test handler mux that response with a list containing a single tenant.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL