You are here

protected function UcAddressesTestCase::constructAddressUrl in Ubercart Addresses 7

Same name and namespace in other branches
  1. 6.2 tests/UcAddressesTestCase.test \UcAddressesTestCase::constructAddressUrl()

Constructs the url for the address book.

If any paths change in the future we only need to change it here.

Parameters

object $account: The user whose address must be deleted

int $aid: (optional) The ID of the address to delete Defaults to NULL

Return value

string

6 calls to UcAddressesTestCase::constructAddressUrl()
UcAddressesAddressBookAdminAllTestCase::testDoubleAddresses in tests/uc_addresses.addressbook.test
Test if double addresses are not saved.
UcAddressesTestCase::createAddress in tests/UcAddressesTestCase.test
Create a new address for an user.
UcAddressesTestCase::deleteAddress in tests/UcAddressesTestCase.test
Delete an address of an user.
UcAddressesTestCase::editAddress in tests/UcAddressesTestCase.test
Edit an address of an user.
UcAddressesTestCase::viewAddress in tests/UcAddressesTestCase.test
View a single address of an user.

... See full list

File

tests/UcAddressesTestCase.test, line 322
Contains base class for Ubercart Addresses tests.

Class

UcAddressesTestCase
Base class for Ubercart Addresses tests.

Code

protected function constructAddressUrl($account, $aid = NULL) {
  $url = 'user/' . $account->uid . '/addresses/';
  if ($aid) {
    $url .= $aid . '/';
  }
  return $url;
}