ILIAS
release_5-4 Revision v5.4.26-12-gabc799a52e6
◀ ilDoc Overview
ilCertificateTemplateTest.php
Go to the documentation of this file.
1
<?
php
2
/* Copyright (c) 1998-2018 ILIAS open source, Extended GPL, see docs/LICENSE */
3
7
class
ilCertificateTemplateTest
extends
\PHPUnit_Framework_TestCase
8
{
9
public
function
testCreateCertificateTemplate
()
10
{
11
$time
= time();
12
13
$template
=
new
ilCertificateTemplate
(
14
100,
15
'crs'
,
16
'<xml>crs</xml>'
,
17
md5(
'<xml>crs</xml>'
),
18
'[]'
,
19
'1'
,
20
'v5.4.0'
,
21
$time
,
22
true
,
23
'/some/where/background.jpg'
,
24
'/some/where/thumbnail.svg'
,
25
555
26
);
27
28
$this->assertEquals(100,
$template
->getObjId());
29
$this->assertEquals(
'crs'
,
$template
->getObjType());
30
$this->assertEquals(
'<xml>crs</xml>'
,
$template
->getCertificateContent());
31
$this->assertEquals(md5(
'<xml>crs</xml>'
),
$template
->getCertificateHash());
32
$this->assertEquals(
'1'
,
$template
->getVersion());
33
$this->assertEquals(
'v5.4.0'
,
$template
->getIliasVersion());
34
$this->assertEquals(
$time
,
$template
->getCreatedTimestamp());
35
$this->assertEquals(
true
,
$template
->isCurrentlyActive());
36
$this->assertEquals(
'/some/where/background.jpg'
,
$template
->getBackgroundImagePath());
37
$this->assertEquals(555,
$template
->getId());
38
}
39
}
$template
$template
Definition:
consentAdmin.php:218
PHPUnit_Framework_TestCase
ilCertificateTemplateTest\testCreateCertificateTemplate
testCreateCertificateTemplate()
Definition:
ilCertificateTemplateTest.php:9
$time
$time
Definition:
cron.php:21
ilCertificateTemplate
Definition:
class.ilCertificateTemplate.php:7
ilCertificateTemplateTest
Definition:
ilCertificateTemplateTest.php:7
php
Services
Certificate
test
samples
ilCertificateTemplateTest.php
Generated on Thu Jan 16 2025 19:02:19 for ILIAS by
1.8.13 (using
Doxyfile
)