Unit tests.  
 More...
◆ setUp()
  
  
      
        
          | assClozeSelectGapTest::setUp  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
protected   | 
  
 
 
◆ test_arrayShuffle_shouldShuffleArray()
      
        
          | assClozeSelectGapTest::test_arrayShuffle_shouldShuffleArray  | 
          ( | 
           | ) | 
           | 
        
      
 
Definition at line 54 of file assClozeSelectGapTest.php.
   57         $expected = [
'shfksdfs', 
'sfsdf', 
'sdfsdfdf'];
    59         $transformationMock = $this->getMockBuilder(Transformation::class)->getMock();
    60         $transformationMock->expects(self::once())->method(
'transform')->willReturn($expected);
    61         $actual = $instance->getItems($transformationMock);
    62         $this->assertEquals($expected, $actual);
 This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
 
 
 
◆ test_getItemswithoutShuffle_shouldReturnItemsInOrder()
      
        
          | assClozeSelectGapTest::test_getItemswithoutShuffle_shouldReturnItemsInOrder  | 
          ( | 
           | ) | 
           | 
        
      
 
Definition at line 101 of file assClozeSelectGapTest.php.
  109         $instance->addItem($item1);
   110         $instance->addItem($item2);
   111         $instance->addItem($item3);
   112         $instance->addItem($item4);
   114         $instance->setType(
false);
   116         $expected = [$item1, $item2, $item3, $item4];
   117         $transformationMock = $this->getMockBuilder(Transformation::class)->getMock();
   118         $transformationMock->expects(self::once())->method(
'transform')->willReturnCallback(
function ($value) {
   121         $actual = $instance->getItems($transformationMock);
   123         $this->assertEquals($expected, $actual);
 This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
 
 
 
◆ test_getItemswithShuffle_shouldReturnShuffledItems()
      
        
          | assClozeSelectGapTest::test_getItemswithShuffle_shouldReturnShuffledItems  | 
          ( | 
           | ) | 
           | 
        
      
 
Definition at line 65 of file assClozeSelectGapTest.php.
   77         $instance->addItem($item1);
    78         $instance->addItem($item2);
    79         $instance->addItem($item3);
    80         $instance->addItem($item4);
    81         $instance->addItem($item5);
    82         $instance->addItem($item6);
    83         $instance->addItem($item7);
    84         $instance->addItem($item8);
    86         $instance->setType(
true);
    88         $sequence = [$item1, $item3, $item2, $item4, $item5, $item6, $item7, $item8];
    89         $expectedSequence = array_reverse($sequence);
    91         $randomElmProvider = $this->getMockBuilder(Transformation::class)->getMock();
    92         $randomElmProvider->expects($this->once())
    95                           ->willReturn($expectedSequence);
    97         $actual = $instance->getItems($randomElmProvider);
    98         $this->assertEquals($actual, $expectedSequence);
 This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
 
 
 
◆ test_instantiateObject_shouldReturnInstance()
      
        
          | assClozeSelectGapTest::test_instantiateObject_shouldReturnInstance  | 
          ( | 
           | ) | 
           | 
        
      
 
Definition at line 37 of file assClozeSelectGapTest.php.
   41         $this->assertInstanceOf(assClozeSelectGap::class, $instance);
 This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
 
 
 
◆ test_newlyInstatiatedObject_shouldReturnTrueOnGetShuffle()
      
        
          | assClozeSelectGapTest::test_newlyInstatiatedObject_shouldReturnTrueOnGetShuffle  | 
          ( | 
           | ) | 
           | 
        
      
 
Definition at line 44 of file assClozeSelectGapTest.php.
   49         $actual = $instance->getShuffle();
    51         $this->assertEquals($expected, $actual);
 This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
 
 
 
◆ $backupGlobals
  
  
      
        
          | assClozeSelectGapTest::$backupGlobals = false | 
         
       
   | 
  
protected   | 
  
 
 
The documentation for this class was generated from the following file: