Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No fallback to REQUEST_TIME in TimeDataCollector #21156

Merged
merged 1 commit into from Jan 6, 2017
Merged

No fallback to REQUEST_TIME in TimeDataCollector #21156

merged 1 commit into from Jan 6, 2017

Conversation

linaori
Copy link
Contributor

@linaori linaori commented Jan 4, 2017

Q A
Branch? master
Bug fix? no
New feature? no
BC breaks? no (?)
Deprecations? no
Tests pass? yes
Fixed tickets ~
License MIT
Doc PR ~

As of PHP 5.4 the REQUEST_TIME_FLOAT is available and the minimum version of PHP is 5.5 in Symfony. I think it's safe to use as I can't find cases where this is not defined.

@fabpot
Copy link
Member

fabpot commented Jan 4, 2017

👍

@@ -29,7 +29,7 @@ public function testCollect()

$c->collect($request, new Response());

$this->assertEquals(1000, $c->getStartTime());
$this->assertEquals(0, $c->getStartTime());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn't you change line 28 instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That test is already covered on line 34. I wanted to keep this case as a regression that REQUEST_TIME is not used when REQUEST_TIME_FLOAT is not filled in

@nicolas-grekas
Copy link
Member

Thank you @iltar.

@nicolas-grekas nicolas-grekas merged commit ba00543 into symfony:master Jan 6, 2017
nicolas-grekas added a commit that referenced this pull request Jan 6, 2017
This PR was merged into the 3.3-dev branch.

Discussion
----------

No fallback to REQUEST_TIME in TimeDataCollector

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no (?)
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | ~
| License       | MIT
| Doc PR        | ~

As of PHP 5.4 the `REQUEST_TIME_FLOAT` is available and the minimum version of PHP is 5.5 in Symfony. I think it's safe to use as I can't find cases where this is _not_ defined.

Commits
-------

ba00543 No fallback to REQUEST_TIME in TimeDataCollector
@linaori linaori deleted the improvement/request-time-float branch February 8, 2019 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants