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

Slim 4 support and PSR-15 #104

Closed
wants to merge 7 commits into from
Closed

Slim 4 support and PSR-15 #104

wants to merge 7 commits into from

Conversation

t0mmy742
Copy link
Contributor

@t0mmy742 t0mmy742 commented Sep 5, 2019

Added support for Slim 4 and PSR-15 (implements MiddlewareInterface).

Also updated composer.json to fit our needs (Slim 4 and PHP set to ^7.1)
Added type-hinting and PHPUnit tests.

I'm using slim/psr7 for tests, but only AppFactory::determineResponseFactory() in source code to let users keep their own providers.

Resolve #102

@t0mmy742 t0mmy742 changed the title Slim 4 Slim 4 support and PSR-15 Sep 5, 2019
README.md Outdated Show resolved Hide resolved
"slim/slim": "~3.0",
"phpunit/phpunit": "^4.0"
"phpunit/phpunit": "^7.5",
"slim/psr7": "^0.5.0"
Copy link
Member

Choose a reason for hiding this comment

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

We don't need Slim/psr7 as a dependency. We can use prophecies to write the unit tests.

*/
public function setUp()
public function setUp(): void
Copy link
Member

Choose a reason for hiding this comment

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

As mentioned in my previous comment, we should use prophecies instead of using an actual implementation to test. I can rewrite the tests for this if you're not quite familiar with that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If you can, yes, I prefer if you rewrite the tests 😄.

@t0mmy742 t0mmy742 requested a review from l0gicgate September 6, 2019 10:32
@l0gicgate l0gicgate mentioned this pull request Sep 9, 2019
1 task
@l0gicgate
Copy link
Member

Follow in #105

@l0gicgate l0gicgate closed this Sep 9, 2019
@t0mmy742 t0mmy742 deleted the slim-4 branch October 3, 2019 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Slim 4 PSR-15 Support
3 participants