-
Notifications
You must be signed in to change notification settings - Fork 407
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
Fixed tests and lint problems in windows #515
Conversation
flight/template/View.php
Outdated
@@ -130,6 +130,7 @@ public function render($file, $data = null) | |||
$this->template = $this->getTemplate($file); | |||
|
|||
if (!file_exists($this->template)) { | |||
$this->template = self::normalizePath($this->template); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this will fix the path....but then it throws an exception so nothing is really fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mean about empty strings?
tests/ViewTest.php
Outdated
} | ||
}; | ||
|
||
self::assertSame( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a huge deal but the rest of the file uses $this->
instead of self::
One thing I've learned that is really important is to keep the codebase as consistent as possible so it doesn't look like "Oh that's definitely a spot fadrian06 coded in". When I code in this framework, even though it drives me nuts, I keep all the class vars lowercase. I would much rather do $Router = Flight::router();
but in order to keep it consistent, I do $router = Flight::router();
simply because it's keeping it consistent.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh sorry, I hadn't noticed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So if you remove the static typing and then correct L111 to be $normalized_template_path_for_error then I think this is good to go.
No description provided.