Code Duplication    Length = 14-14 lines in 2 locations

tests/php/unit/Controller/CollectionsControllerTest.php 1 location

@@ 42-55 (lines=14) @@
39
	/**
40
	 * Gets run before each test
41
	 */
42
	public function setUp(): void {
43
		$this->appName = 'tasks';
44
		$this->collectionsService = $this->getMockBuilder(CollectionsService::class)
45
			->disableOriginalConstructor()
46
			->getMock();
47
		$this->request = $this->getMockBuilder(IRequest::class)
48
			->disableOriginalConstructor()
49
			->getMock();
50
		$this->controller = new CollectionsController(
51
			$this->appName,
52
			$this->request,
53
			$this->collectionsService
54
		);
55
	}
56
57
	public function testgetCollections() {
58
		$return = [[], []];

tests/php/unit/Controller/SettingsControllerTest.php 1 location

@@ 42-55 (lines=14) @@
39
	/**
40
	 * Gets run before each test
41
	 */
42
	public function setUp(): void {
43
		$this->appName = 'tasks';
44
		$this->settingsService = $this->getMockBuilder(SettingsService::class)
45
			->disableOriginalConstructor()
46
			->getMock();
47
		$this->request = $this->getMockBuilder(IRequest::class)
48
			->disableOriginalConstructor()
49
			->getMock();
50
		$this->controller = new SettingsController(
51
			$this->appName,
52
			$this->request,
53
			$this->settingsService
54
		);
55
	}
56
57
	public function testSet() {
58
		$this->settingsService->expects($this->once())