1<?php
2/**
3 * PHP version 5
4 * Test the Horde_Auth_Passwd:: class.
5 *
6 * Copyright 2010-2017 Horde LLC (http://www.horde.org/)
7 *
8 * See the enclosed file COPYING for license information (LGPL). If you
9 * did not receive this file, see http://www.horde.org/licenses/lgpl21.
10 *
11 * @category   Horde
12 * @package    Auth
13 * @subpackage UnitTests
14 * @author     Gunnar Wrobel <wrobel@pardus.de>
15 * @license    http://www.horde.org/licenses/lgpl21 LGPL-2.1
16 * @link       http://pear.horde.org/index.php?package=Auth
17 */
18class Horde_Auth_Unit_PasswdTest extends Horde_Auth_TestCase
19{
20    public function setUp()
21    {
22        $this->driver = new Horde_Auth_Passwd(
23            array('filename' => __DIR__ . '/../fixtures/test.passwd')
24        );
25    }
26
27    public function testAuthenticate()
28    {
29        $this->assertTrue($this->driver->authenticate('user', array('password' => 'password')));
30    }
31
32    public function testListUsers()
33    {
34        $this->assertEquals(array('user'), $this->driver->listUsers());
35    }
36}
37