blob: 34731cdb1d10a592aaf7c556916da92b7018bab9 [file] [log] [blame]
package extensions
import (
"testing"
"github.com/rackspace/gophercloud"
th "github.com/rackspace/gophercloud/testhelper"
)
const Endpoint = "http://localhost:57909/"
func EndpointClient() *gophercloud.ServiceClient {
return &gophercloud.ServiceClient{Endpoint: Endpoint}
}
func TestExtensionURL(t *testing.T) {
actual := ExtensionURL(EndpointClient(), "agent")
expected := Endpoint + "v2.0/extensions/agent"
th.AssertEquals(t, expected, actual)
}
func TestListExtensionURL(t *testing.T) {
actual := ListExtensionURL(EndpointClient())
expected := Endpoint + "v2.0/extensions"
th.AssertEquals(t, expected, actual)
}