ILIAS  trunk Revision v12.0_alpha-399-g579a087ced2
ilUserCertificateTest Class Reference
+ Inheritance diagram for ilUserCertificateTest:
+ Collaboration diagram for ilUserCertificateTest:

Public Member Functions

 testCreateUserCertificate ()
 

Additional Inherited Members

- Protected Member Functions inherited from ilCertificateBaseTestCase
 setUp ()
 
 tearDown ()
 
 assertDoesNotThrow (callable $cb, string $message='')
 
 assertThrows (callable $cb, ?string $expected_class=null, ?string $expected_message=null)
 @template T of Throwable More...
 
 setGlobalVariable (string $name, mixed $value)
 
- Protected Attributes inherited from ilCertificateBaseTestCase
Container $dic
 

Detailed Description

Definition at line 23 of file ilUserCertificateTest.php.

Member Function Documentation

◆ testCreateUserCertificate()

ilUserCertificateTest::testCreateUserCertificate ( )

Definition at line 25 of file ilUserCertificateTest.php.

25 : void
26 {
27 $userCertificate = new ilUserCertificate(
28 1,
29 20,
30 'crs',
31 400,
32 'Niels Theen',
33 123_456_789,
34 '<xml>Some Content</xml>',
35 '[]',
36 null,
37 1,
38 'v5.4.0',
39 true,
40 new CertificateId('11111111-2222-3333-4444-555555555555'),
41 '',
42 '',
43 140,
44 );
45
46 $this->assertSame(1, $userCertificate->getPatternCertificateId());
47 $this->assertSame(20, $userCertificate->getObjId());
48 $this->assertSame('crs', $userCertificate->getObjType());
49 $this->assertSame(400, $userCertificate->getUserId());
50 $this->assertSame('Niels Theen', $userCertificate->getUserName());
51 $this->assertSame(123_456_789, $userCertificate->getAcquiredTimestamp());
52 $this->assertSame('<xml>Some Content</xml>', $userCertificate->getCertificateContent());
53 $this->assertSame('[]', $userCertificate->getTemplateValues());
54 $this->assertEquals(0, $userCertificate->getValidUntil());
55 $this->assertSame(1, $userCertificate->getVersion());
56 $this->assertSame('v5.4.0', $userCertificate->getIliasVersion());
57 $this->assertTrue($userCertificate->isCurrentlyActive());
58 $this->assertSame(140, $userCertificate->getId());
59 $this->assertSame('11111111-2222-3333-4444-555555555555', $userCertificate->getCertificateId()->asString());
60 }

The documentation for this class was generated from the following file: