Proyectos de Subversion Moodle

Rev

Rev 11 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 11 Rev 1441
Línea 41... Línea 41...
41
 * @package    core_webservice
41
 * @package    core_webservice
42
 * @category   test
42
 * @category   test
43
 * @copyright  2016 Jun Pataleta <jun@moodle.com>
43
 * @copyright  2016 Jun Pataleta <jun@moodle.com>
44
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
44
 * @license    http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
45
 */
45
 */
46
class lib_test extends \advanced_testcase {
46
final class lib_test extends \advanced_testcase {
Línea 47... Línea 47...
47
 
47
 
48
    /**
48
    /**
49
     * Setup.
49
     * Setup.
50
     */
50
     */
Línea 267... Línea 267...
267
    /**
267
    /**
268
     * Data provider for {@see test_get_active_tokens}
268
     * Data provider for {@see test_get_active_tokens}
269
     *
269
     *
270
     * @return array
270
     * @return array
271
     */
271
     */
272
    public function get_active_tokens_provider(): array {
272
    public static function get_active_tokens_provider(): array {
273
        return [
273
        return [
274
            'No expiration' => [0, true],
274
            'No expiration' => [0, true],
275
            'Active' => [time() + DAYSECS, true],
275
            'Active' => [time() + DAYSECS, true],
276
            'Expired' => [time() - DAYSECS, false],
276
            'Expired' => [time() - DAYSECS, false],
277
        ];
277
        ];