ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilWebDAVObjDAVHelperTest Class Reference

Created by PhpStorm. More...

+ Inheritance diagram for ilWebDAVObjDAVHelperTest:
+ Collaboration diagram for ilWebDAVObjDAVHelperTest:

Public Member Functions

 isDAVableObjType_giveInvalidType_returnsFalse ()
 
 isDAVableObjType_giveValidType_returnsTrue ()
 
 isDAVableObjTitle_giveJustLetters_returnsTrue ()
 

Detailed Description

Created by PhpStorm.

User: adm_her Date: 15.10.18 Time: 15:32 Just some tests for ilWebDAVObjDAVHelper

Definition at line 12 of file ilWebDAVObjDAVHelperTest.php.

Member Function Documentation

◆ isDAVableObjTitle_giveJustLetters_returnsTrue()

ilWebDAVObjDAVHelperTest::isDAVableObjTitle_giveJustLetters_returnsTrue ( )
Test:

Definition at line 55 of file ilWebDAVObjDAVHelperTest.php.

56  {
57  // Arrange
58  $tested_title = 'hello';
59  $mock_repo_helper = \Mockery::mock('ilWebDAVRepositoryHelper');
60  $dav_helper = new ilWebDAVObjDAVHelper($mock_repo_helper);
61 
62  // Act
63  $is_davable = $dav_helper->isDAVableObjTitle($tested_title);
64 
65  // Assert
66  $this->assertTrue($is_davable == true);
67  }
Class ilWebDAVObjDAVHelper.

◆ isDAVableObjType_giveInvalidType_returnsFalse()

ilWebDAVObjDAVHelperTest::isDAVableObjType_giveInvalidType_returnsFalse ( )
Test:

Definition at line 19 of file ilWebDAVObjDAVHelperTest.php.

20  {
21  // Arrange
22  $tested_type = 'invalid';
23  $mock_repo_helper = \Mockery::mock('ilWebDAVRepositoryHelper');
24  $dav_helper = new ilWebDAVObjDAVHelper($mock_repo_helper);
25 
26  // Act
27  $is_davable = $dav_helper->isDAVableObjType($tested_type);
28 
29  // Assert
30  $this->assertTrue($is_davable == false);
31  }
Class ilWebDAVObjDAVHelper.

◆ isDAVableObjType_giveValidType_returnsTrue()

ilWebDAVObjDAVHelperTest::isDAVableObjType_giveValidType_returnsTrue ( )
Test:

Definition at line 37 of file ilWebDAVObjDAVHelperTest.php.

38  {
39  // Arrange
40  $tested_type = 'file';
41  $mock_repo_helper = \Mockery::mock('ilWebDAVRepositoryHelper');
42  $dav_helper = new ilWebDAVObjDAVHelper($mock_repo_helper);
43 
44  // Act
45  $is_davable = $dav_helper->isDAVableObjType($tested_type);
46 
47  // Assert
48  $this->assertTrue($is_davable == true);
49  }
Class ilWebDAVObjDAVHelper.

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