I'm writing up unit tests for my plugin and I need a logged in user to test, but I can't find the admin password anywhere. Does anybody know what the default admin password is? I'm extending the WP_UnitTestCase and taking the tests from https://unit-tests.svn.wordpress.org/trunk.

My code at the moment:


class MyPluginTest extends WP_UnitTestCase{

    function setUp(){
            'user_login' => 'admin',
            'user_password' => 'no_idea'

any help would be appreciated.

1 Answer 1


The password is … password. You can see that in includes/install.php:

wp_install( WP_TESTS_TITLE, 'admin', WP_TESTS_EMAIL, true, null, 'password' );

The last parameter is the admin password.

  • I feel like a pleb, almost so much as to remove the question out of embarrassment ;) cheers.
    – Daithí
    May 1, 2013 at 13:13
  • 1
    @Coombesy It is not that bad. The password should be mentioned in the readme file. Now, when someone else searches for it, it can be found with a Google search.
    – fuxia
    May 1, 2013 at 13:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.