Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
language: php

php:
- 5.6
- 7.0
- 7.1

Expand All @@ -11,9 +10,9 @@ env:

matrix:
include:
- php: 5.6
- php: 7.0
env: setup=lowest
- php: 5.6
- php: 7.0
env: setup=stable

sudo: false
Expand Down
10 changes: 6 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,19 @@
}
],
"require": {
"php": ">=5.6.4"
"php": "~7.0"
},
"replace": {
"fist/container": "self.version",
"fist/database": "self.version",
"fist/repository": "self.version",
"fist/routing": "self.version",
"fist/facade": "self.version",
"fist/testing": "self.version"
"fist/testing": "self.version",
"fist/request": "self.version"
},
"require-dev": {
"phpunit/phpunit": "~5.4",
"phpunit/phpunit": "~6.0",
"codacy/coverage": "dev-master",
"sllh/php-cs-fixer-styleci-bridge": "^2.1"
},
Expand All @@ -37,7 +38,8 @@
"Fist\\Repository\\": "src/Fist/Repository/src/",
"Fist\\Routing\\": "src/Fist/Routing/src/",
"Fist\\Facade\\": "src/Fist/Facade/src/",
"Fist\\Testing\\": "src/Fist/Testing/src/"
"Fist\\Testing\\": "src/Fist/Testing/src/",
"Fist\\Http\\": "src/Fist/Http/src/"
}
},
"extra": {
Expand Down
5 changes: 2 additions & 3 deletions src/Fist/Container/.travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
language: php

php:
- 5.6
- 7.0
- 7.1

Expand All @@ -11,9 +10,9 @@ env:

matrix:
include:
- php: 5.6
- php: 7.0
env: setup=lowest
- php: 5.6
- php: 7.0
env: setup=stable

sudo: false
Expand Down
4 changes: 2 additions & 2 deletions src/Fist/Container/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
}
],
"require": {
"php": ">=5.6.4"
"php": "~7.0"
},
"require-dev": {
"phpunit/phpunit": "~5.4",
"phpunit/phpunit": "~6.0",
"fist/testing": "self.version"
},
"autoload": {
Expand Down
3 changes: 3 additions & 0 deletions src/Fist/Container/tests/ContainerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
use Fist\Testing\TestCase;
use Fist\Container\Container;

/**
* @SuppressWarnings(PHPMD.TooManyPublicMethods)
*/
class ContainerTest extends TestCase
{
public function testContainerBuilding()
Expand Down
5 changes: 2 additions & 3 deletions src/Fist/Database/.travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
language: php

php:
- 5.6
- 7.0
- 7.1

Expand All @@ -11,9 +10,9 @@ env:

matrix:
include:
- php: 5.6
- php: 7.0
env: setup=lowest
- php: 5.6
- php: 7.0
env: setup=stable

sudo: false
Expand Down
4 changes: 2 additions & 2 deletions src/Fist/Database/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
}
],
"require": {
"php": ">=5.6.4",
"php": "~7.0",
"fist/repository": "self.version"
},
"require-dev": {
"phpunit/phpunit": "~5.4",
"phpunit/phpunit": "~6.0",
"fist/testing": "self.version",
"fist/container": "self.version"
},
Expand Down
3 changes: 3 additions & 0 deletions src/Fist/Database/tests/DatabaseConnectionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
use Fist\Database\Connectors\SqliteConnection;
use Fist\Database\Connectors\ConnectionInterface;

/**
* @SuppressWarnings(PHPMD.TooManyPublicMethods)
*/
class DatabaseConnectionTest extends TestCase
{
use WithDatabase;
Expand Down
5 changes: 2 additions & 3 deletions src/Fist/Facade/.travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
language: php

php:
- 5.6
- 7.0
- 7.1

Expand All @@ -11,9 +10,9 @@ env:

matrix:
include:
- php: 5.6
- php: 7.0
env: setup=lowest
- php: 5.6
- php: 7.0
env: setup=stable

sudo: false
Expand Down
4 changes: 2 additions & 2 deletions src/Fist/Facade/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
}
],
"require": {
"php": ">=5.6.4"
"php": "~7.0"
},
"require-dev": {
"phpunit/phpunit": "~5.4",
"phpunit/phpunit": "~6.0",
"fist/testing": "self.version",
"fist/container": "self.version"
},
Expand Down
3 changes: 3 additions & 0 deletions src/Fist/Facade/tests/FacadeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
use Fist\Container\Container;
use Fist\Facade\ContainerFacade;

/**
* @SuppressWarnings(PHPMD.TooManyPublicMethods)
*/
class FacadeTest extends TestCase
{
public function testCallingFacade()
Expand Down
3 changes: 3 additions & 0 deletions src/Fist/Http/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
vendor/
composer.lock
.subsplit/
32 changes: 32 additions & 0 deletions src/Fist/Http/.travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
language: php

php:
- 7.0
- 7.1

env:
global:
- setup=basic

matrix:
include:
- php: 7.0
env: setup=lowest
- php: 7.0
env: setup=stable

sudo: false

before_install:
- if [[ $TRAVIS_PHP_VERSION != 7.1 ]] ; then phpenv config-rm xdebug.ini; fi
- travis_retry composer self-update

install:
- if [[ $setup = 'basic' ]]; then travis_retry composer install --no-interaction --prefer-dist --no-suggest; fi
- if [[ $setup = 'stable' ]]; then travis_retry composer update --prefer-dist --no-interaction --prefer-stable --no-suggest; fi
- if [[ $setup = 'lowest' ]]; then travis_retry composer update --prefer-dist --no-interaction --prefer-lowest --prefer-stable --no-suggest; fi

script: vendor/bin/phpunit

matrix:
fast_finish: true
35 changes: 35 additions & 0 deletions src/Fist/Http/composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"name": "fist/http",
"description": "The Fistlab PHP Container Components",
"keywords": ["fistlab", "fistphp", "component", "http"],
"license": "MIT",
"homepage": "https://github.com/fistphp/http",
"support": {
"issues": "https://github.com/fistlab/php/issues",
"source": "https://github.com/fistlab/php"
},
"authors": [
{
"name": "Mark Topper",
"email": "mark@ulties.com"
}
],
"require": {
"php": "~7.0"
},
"require-dev": {
"phpunit/phpunit": "~6.0",
"fist/testing": "self.version"
},
"autoload": {
"psr-4": {
"Fist\\Http\\": "src/"
}
},
"extra": {
"branch-alias": {
"dev-master": "1.0-dev"
}
},
"minimum-stability": "dev"
}
21 changes: 21 additions & 0 deletions src/Fist/Http/license.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2016 Fistlab

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
20 changes: 20 additions & 0 deletions src/Fist/Http/phpunit.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="false"
backupStaticAttributes="false"
bootstrap="tests/bootstrap.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnError="false"
stopOnFailure="false"
syntaxCheck="true"
verbose="true"
>
<testsuites>
<testsuite name="Fistlab Test Suite">
<directory suffix="Test.php">./tests</directory>
</testsuite>
</testsuites>
</phpunit>
39 changes: 39 additions & 0 deletions src/Fist/Http/src/AbstractBag.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?php

namespace Fist\Http;

abstract class AbstractBag
{
protected $items;

public function __construct(array $items)
{
$this->items = $items;
}

public function get($key, $default = null)
{
if ($this->has($key)) {
return $this->items[$key];
}

return $default;
}

public function has($key)
{
return isset($this->items[$key]);
}

public function set($key, $value)
{
$this->items[$key] = $value;

return $this;
}

public function all()
{
return $this->items;
}
}
7 changes: 7 additions & 0 deletions src/Fist/Http/src/CookieBag.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

namespace Fist\Http;

class CookieBag extends AbstractBag
{
}
7 changes: 7 additions & 0 deletions src/Fist/Http/src/FileBag.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

namespace Fist\Http;

class FileBag extends AbstractBag
{
}
7 changes: 7 additions & 0 deletions src/Fist/Http/src/HeaderBag.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

namespace Fist\Http;

class HeaderBag extends AbstractBag
{
}
7 changes: 7 additions & 0 deletions src/Fist/Http/src/ParameterBag.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

namespace Fist\Http;

class ParameterBag extends AbstractBag
{
}
Loading