Code Duplication    Length = 24-24 lines in 2 locations

tests/controller/phpbbdirectory_base_test.php 1 location

@@ 38-61 (lines=24) @@
35
		$this->user->style['style_path'] = 'prosilver';
36
	}
37
38
	public function get_controller()
39
	{
40
		global $table_categories, $tables_comments, $tables_links, $tables_votes, $tables_watch;
41
		global $phpbb_path_helper, $phpbb_extension_manager;
42
43
		$controller = new \ernadoo\phpbbdirectory\controller\categories(
44
			$this->db,
45
			$this->config,
46
			$this->lang,
47
			$this->template,
48
			$this->user,
49
			$this->helper,
50
			$this->request,
51
			$this->auth,
52
			$this->pagination,
53
			$this->core_categorie,
54
			$this->core_link
55
		);
56
		$controller->set_tables($table_categories, $tables_comments, $tables_links, $tables_votes, $tables_watch);
57
		$controller->set_path_helper($phpbb_path_helper);
58
		$controller->set_extension_manager($phpbb_extension_manager);
59
60
		return $controller;
61
	}
62
63
	/**
64
	* Test data for the test_display_base() function

tests/controller/phpbbdirectory_cats_test.php 1 location

@@ 42-65 (lines=24) @@
39
		$this->config['dir_show'] = 5;
40
	}
41
42
	public function get_controller()
43
	{
44
		global $table_categories, $tables_comments, $tables_links, $tables_votes, $tables_watch;
45
		global $phpbb_path_helper, $phpbb_extension_manager;
46
47
		$controller = new \ernadoo\phpbbdirectory\controller\categories(
48
			$this->db,
49
			$this->config,
50
			$this->lang,
51
			$this->template,
52
			$this->user,
53
			$this->helper,
54
			$this->request,
55
			$this->auth,
56
			$this->pagination,
57
			$this->core_categorie,
58
			$this->core_link
59
		);
60
		$controller->set_tables($table_categories, $tables_comments, $tables_links, $tables_votes, $tables_watch);
61
		$controller->set_path_helper($phpbb_path_helper);
62
		$controller->set_extension_manager($phpbb_extension_manager);
63
64
		return $controller;
65
	}
66
67
	/**
68
	* Test data for the test_display_cat_by_id() function