Skip to content

Commit

Permalink
test(form, category): fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
btry committed Jan 25, 2024
1 parent 55530d9 commit 8e356d3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions tests/3-unit/PluginFormcreatorCategory.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ public function testGetTypeName($nb, $expected) {
}

public function testDefineTabs() {
$this->login('glpi', 'glpi');
$instance = $this->newTestedInstance();
$output = $instance->defineTabs();
$expected = [
Expand Down
3 changes: 3 additions & 0 deletions tests/3-unit/PluginFormcreatorForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,8 @@ public function testPrepareInputForUpdate($input, $expected, $expectedMessage) {
}

public function testDefineTabs() {
$this->login('glpi', 'glpi');
$_SESSION['glpishow_count_on_tabs'] = 0;
$instance = $this->newTestedInstance();
$output = $instance->defineTabs();
$expected = [
Expand All @@ -311,6 +313,7 @@ public function testDefineTabs() {
'PluginFormcreatorForm$3' => "Form answer properties",
'PluginFormcreatorFormAnswer$1' => "Form answers",
'PluginFormcreatorForm_Language$1' => 'Form languages',
'Document_Item$1' => "Documents",
'Log$1' => "Historical",
];
$this->array($output)
Expand Down

0 comments on commit 8e356d3

Please sign in to comment.