ILIAS
release_7 Revision v7.30-3-g800a261c036
◀ ilDoc Overview
Main Page
Related Pages
Modules
+
Namespaces
Namespace List
+
Namespace Members
+
All
$
_
a
b
c
d
e
f
g
h
i
j
l
m
p
r
s
t
w
+
Functions
_
a
b
c
f
g
h
i
r
s
t
w
+
Variables
$
c
d
e
f
g
h
j
l
m
p
s
t
+
Data Structures
Data Structures
Data Structure Index
Class Hierarchy
+
Data Fields
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Files
File List
+
Globals
+
All
$
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
+
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
+
Variables
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Examples
▼
ILIAS
Test List
Todo List
Deprecated List
►
Modules
►
Namespaces
►
Data Structures
▼
Files
►
File List
►
Globals
►
Examples
•
All
Data Structures
Namespaces
Files
Functions
Variables
Modules
Pages
ilTestFinalMarkLangVarBuilderTest.php
Go to the documentation of this file.
1
<?php
2
/* Copyright (c) 1998-2013 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4
use
PHPUnit\Framework\TestCase
;
5
16
class
ilTestFinalMarkLangVarBuilderTest
extends
TestCase
17
{
18
protected
$backupGlobals
=
false
;
19
20
protected
function
setUp
() : void
21
{
22
if
(defined(
'ILIAS_PHPUNIT_CONTEXT'
)) {
23
include_once(
"./Services/PHPUnit/classes/class.ilUnitUtil.php"
);
24
ilUnitUtil::performInitialisation();
25
}
else
{
26
chdir(dirname(__FILE__));
27
chdir(
'../../../'
);
28
}
29
}
30
34
public
function
test_build
()
35
{
36
$testCases = array(
37
array(
38
'param_passedStatus'
=>
false
,
'param_obligationsAnsweredStatus'
=>
false
,
'param_obligationsEnabled'
=>
false
,
39
'expected'
=>
'mark_tst_failed'
40
),
41
array(
42
'param_passedStatus'
=>
false
,
'param_obligationsAnsweredStatus'
=>
false
,
'param_obligationsEnabled'
=>
true
,
43
'expected'
=>
'mark_tst_failed_obligations_missing'
44
),
45
array(
46
'param_passedStatus'
=>
false
,
'param_obligationsAnsweredStatus'
=>
true
,
'param_obligationsEnabled'
=>
false
,
47
'expected'
=>
'mark_tst_failed'
48
),
49
array(
50
'param_passedStatus'
=>
false
,
51
'param_obligationsAnsweredStatus'
=>
true
,
52
'param_obligationsEnabled'
=>
true
,
53
'expected'
=>
'mark_tst_failed_obligations_answered'
54
),
55
array(
56
'param_passedStatus'
=>
true
,
57
'param_obligationsAnsweredStatus'
=>
false
,
58
'param_obligationsEnabled'
=>
false
,
59
'expected'
=>
'mark_tst_passed'
60
),
61
array(
62
'param_passedStatus'
=>
true
,
63
'param_obligationsAnsweredStatus'
=>
false
,
64
'param_obligationsEnabled'
=>
true
,
65
'expected'
=>
'mark_tst_failed_obligations_missing'
66
),
67
array(
68
'param_passedStatus'
=>
true
,
69
'param_obligationsAnsweredStatus'
=>
true
,
70
'param_obligationsEnabled'
=>
false
,
71
'expected'
=>
'mark_tst_passed'
72
),
73
array(
74
'param_passedStatus'
=>
true
,
75
'param_obligationsAnsweredStatus'
=>
true
,
76
'param_obligationsEnabled'
=>
true
,
77
'expected'
=>
'mark_tst_passed_obligations_answered'
78
)
79
);
80
// OTX: Test breaks with fatal error...
81
// foreach($testCases as $case)
82
// {
83
// // arrange
84
//
85
// $passedStatus = $case['param_passedStatus'];
86
// $obligationsAnsweredStatus = $case['param_obligationsAnsweredStatus'];
87
// $obligationsEnabled = $case['param_obligationsEnabled'];
88
//
89
// $expected = $case['expected'];
90
//
91
// require_once './Modules/Test/classes/class.ilTestFinalMarkLangVarBuilder.php';
92
// $instance = new ilTestFinalMarkLangVarBuilder($passedStatus, $obligationsAnsweredStatus, $obligationsEnabled);
93
//
94
// // act
95
//
96
// $actual = $instance->build();
97
//
98
// // assert
99
//
100
// $this->assertEquals($expected, $actual);
101
// }
102
}
103
}
ilTestFinalMarkLangVarBuilderTest\test_build
test_build()
Definition:
ilTestFinalMarkLangVarBuilderTest.php:34
ilTestFinalMarkLangVarBuilderTest
Definition:
ilTestFinalMarkLangVarBuilderTest.php:16
ilTestFinalMarkLangVarBuilderTest\$backupGlobals
$backupGlobals
Definition:
ilTestFinalMarkLangVarBuilderTest.php:18
ilTestFinalMarkLangVarBuilderTest\setUp
setUp()
Definition:
ilTestFinalMarkLangVarBuilderTest.php:20
TestCase
Modules
Test
test
ilTestFinalMarkLangVarBuilderTest.php
Generated on Fri Apr 4 2025 21:01:11 for ILIAS by
1.8.13 (using
Doxyfile
)