@@ 530-563 (lines=34) @@ | ||
527 | $this->assertSame('', $this->invokePrivate($this->checkSetupController, 'isUsedTlsLibOutdated')); |
|
528 | } |
|
529 | ||
530 | public function testIsUsedTlsLibOutdatedWithAppstoreDisabledAndServerToServerSharingEnabled() { |
|
531 | // Appstore is disabled by default in EE |
|
532 | $appStoreDefault = false; |
|
533 | if (\OC_Util::getEditionString() === '') { |
|
534 | $appStoreDefault = true; |
|
535 | } |
|
536 | ||
537 | $this->config |
|
538 | ->expects($this->at(0)) |
|
539 | ->method('getSystemValue') |
|
540 | ->with('has_internet_connection', true) |
|
541 | ->will($this->returnValue(true)); |
|
542 | $this->config |
|
543 | ->expects($this->at(1)) |
|
544 | ->method('getSystemValue') |
|
545 | ->with('appstoreenabled', $appStoreDefault) |
|
546 | ->will($this->returnValue(false)); |
|
547 | $this->config |
|
548 | ->expects($this->at(2)) |
|
549 | ->method('getAppValue') |
|
550 | ->with('files_sharing', 'outgoing_server2server_share_enabled', 'yes') |
|
551 | ->will($this->returnValue('no')); |
|
552 | $this->config |
|
553 | ->expects($this->at(3)) |
|
554 | ->method('getAppValue') |
|
555 | ->with('files_sharing', 'incoming_server2server_share_enabled', 'yes') |
|
556 | ->will($this->returnValue('yes')); |
|
557 | ||
558 | $this->checkSetupController |
|
559 | ->expects($this->once()) |
|
560 | ->method('getCurlVersion') |
|
561 | ->will($this->returnValue([])); |
|
562 | $this->assertSame('', $this->invokePrivate($this->checkSetupController, 'isUsedTlsLibOutdated')); |
|
563 | } |
|
564 | ||
565 | public function testIsUsedTlsLibOutdatedWithAppstoreDisabledAndServerToServerSharingDisabled() { |
|
566 | // Appstore is disabled by default in EE |
|
@@ 565-598 (lines=34) @@ | ||
562 | $this->assertSame('', $this->invokePrivate($this->checkSetupController, 'isUsedTlsLibOutdated')); |
|
563 | } |
|
564 | ||
565 | public function testIsUsedTlsLibOutdatedWithAppstoreDisabledAndServerToServerSharingDisabled() { |
|
566 | // Appstore is disabled by default in EE |
|
567 | $appStoreDefault = false; |
|
568 | if (\OC_Util::getEditionString() === '') { |
|
569 | $appStoreDefault = true; |
|
570 | } |
|
571 | ||
572 | $this->config |
|
573 | ->expects($this->at(0)) |
|
574 | ->method('getSystemValue') |
|
575 | ->with('has_internet_connection', true) |
|
576 | ->will($this->returnValue(true)); |
|
577 | $this->config |
|
578 | ->expects($this->at(1)) |
|
579 | ->method('getSystemValue') |
|
580 | ->with('appstoreenabled', $appStoreDefault) |
|
581 | ->will($this->returnValue(false)); |
|
582 | $this->config |
|
583 | ->expects($this->at(2)) |
|
584 | ->method('getAppValue') |
|
585 | ->with('files_sharing', 'outgoing_server2server_share_enabled', 'yes') |
|
586 | ->will($this->returnValue('no')); |
|
587 | $this->config |
|
588 | ->expects($this->at(3)) |
|
589 | ->method('getAppValue') |
|
590 | ->with('files_sharing', 'incoming_server2server_share_enabled', 'yes') |
|
591 | ->will($this->returnValue('no')); |
|
592 | ||
593 | $this->checkSetupController |
|
594 | ->expects($this->never()) |
|
595 | ->method('getCurlVersion') |
|
596 | ->will($this->returnValue([])); |
|
597 | $this->assertSame('', $this->invokePrivate($this->checkSetupController, 'isUsedTlsLibOutdated')); |
|
598 | } |
|
599 | } |
|
600 |