mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
BUGFIX: disable basic auth for the restful controller test (from r109714)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@112829 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
0154fbae0f
commit
29ca5ff9a7
@ -135,9 +135,12 @@ class RestfulServiceTest extends SapphireTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class RestfulServiceTest_Controller extends Controller {
|
class RestfulServiceTest_Controller extends Controller {
|
||||||
|
public function init() {
|
||||||
|
$this->basicAuthEnabled = false;
|
||||||
|
parent::init();
|
||||||
|
}
|
||||||
|
|
||||||
public function index() {
|
public function index() {
|
||||||
BasicAuth::protect_entire_site(false);
|
|
||||||
|
|
||||||
$request = '';
|
$request = '';
|
||||||
foreach ($this->request->requestVars() as $key=>$value) {
|
foreach ($this->request->requestVars() as $key=>$value) {
|
||||||
$request .= "\t\t<request_item name=\"$key\">$value</request_item>\n";
|
$request .= "\t\t<request_item name=\"$key\">$value</request_item>\n";
|
||||||
@ -168,7 +171,6 @@ XML;
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function invalid() {
|
public function invalid() {
|
||||||
BasicAuth::protect_entire_site(false);
|
|
||||||
$out = <<<XML
|
$out = <<<XML
|
||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<test>
|
<test>
|
||||||
|
Loading…
Reference in New Issue
Block a user