Code Duplication    Length = 6-6 lines in 2 locations

tests/model/VersionedTest.php 1 location

@@ 419-424 (lines=6) @@
416
	 *
417
	 * @param int $minutes
418
	 */
419
	protected function sleep($minutes) {
420
		$now = SS_Datetime::now();
421
		$date = DateTime::createFromFormat('Y-m-d H:i:s', $now->getValue());
422
		$date->modify("+{$minutes} minutes");
423
		SS_Datetime::set_mock_now($date->format('Y-m-d H:i:s'));
424
	}
425
426
	/**
427
	 * Tests records selected by specific version

tests/model/VersionedOwnershipTest.php 1 location

@@ 44-49 (lines=6) @@
41
	 *
42
	 * @param int $minutes
43
	 */
44
	protected function sleep($minutes) {
45
		$now = SS_Datetime::now();
46
		$date = DateTime::createFromFormat('Y-m-d H:i:s', $now->getValue());
47
		$date->modify("+{$minutes} minutes");
48
		SS_Datetime::set_mock_now($date->format('Y-m-d H:i:s'));
49
	}
50
51
	/**
52
	 * Test basic findOwned() in stage mode