rounding rules via admin screen, round begin when starting record (#1229)

This commit is contained in:
Kevin Papst
2019-11-10 13:57:05 +01:00
committed by GitHub
parent fa1c79e15c
commit c6c4098759
47 changed files with 1100 additions and 185 deletions

View File

@@ -15,8 +15,7 @@ use App\Entity\Activity;
use App\Entity\Customer;
use App\Entity\Project;
use App\Entity\Timesheet;
use App\Tests\Mocks\Security\UserDateTimeFactoryFactory;
use App\Timesheet\TrackingModeService;
use App\Tests\Mocks\TrackingModeServiceFactory;
use App\Validator\Constraints\Timesheet as TimesheetConstraint;
use App\Validator\Constraints\TimesheetValidator;
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
@@ -39,10 +38,8 @@ class TimesheetValidatorTest extends ConstraintValidatorTestCase
'rules' => [
'allow_future_times' => false,
],
'mode' => 'default',
]);
$dateTime = (new UserDateTimeFactoryFactory($this))->create();
$service = new TrackingModeService($dateTime, $config);
$service = (new TrackingModeServiceFactory($this))->create('default');
return new TimesheetValidator($authMock, $config, $service);
}