Currently only the username and password fields are provided in the settings. Since basic and digest are fairly common it should support the ability to switch between them easily.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

boombatower’s picture

Assigned: Unassigned » boombatower
Status: Active » Needs review
FileSize
5.79 KB
boombatower’s picture

Hmmm, that patch was messed up.

boombatower’s picture

Double fail.

Dave Reid’s picture

+++ modules/simpletest/drupal_web_test_case.php	28 Dec 2009 21:42:50 -0000
@@ -415,6 +415,7 @@
+    $this->httpauth_method = variable_get('simpletest_method', CURLAUTH_BASIC);

Would seem to make more sense to have this variable's name be simpletest_httpauth_method. Little longer, but self-documenting.

+++ modules/simpletest/simpletest.pages.inc	28 Dec 2009 21:42:50 -0000
@@ -442,8 +442,23 @@
+    '#options' => array(
+      CURLAUTH_BASIC => t('Basic'),
+      CURLAUTH_DIGEST => t('Digest'),
+      CURLAUTH_GSSNEGOTIATE => t('GSS negotiate'),
+      CURLAUTH_NTLM => t('NTLM'),
+      CURLAUTH_ANY => t('Any'),
+      CURLAUTH_ANYSAFE => t('Any safe'),
+    ),

Do we need to explain these values at all or the fact that Any and the Any safe options are catch-all options?

This review is powered by Dreditor.

boombatower’s picture

Decided that this is dev setting, so we can assume they know them or can look them up and don't need/want to clutter this.

Renamed all related variables to httpauth_.

Dave Reid’s picture

Status: Needs review » Reviewed & tested by the community

Looks good. Upgrade path isn't necessary since this is a 'new' module (although we should put one in the 6.x-2.x backport).

Dries’s picture

Status: Reviewed & tested by the community » Fixed

Committed to CVS HEAD. Thanks boombatower.

cburschka’s picture

In order to be able to use this in all PHP environments, it would be helpful if this patch could be looked at: #670454: Support HTTP Authorization in CGI environment. :-)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.