Skip to content

Commit 8dc7b31

Browse files
Project meta files
1 parent 274c19c commit 8dc7b31

File tree

5 files changed

+140
-0
lines changed

5 files changed

+140
-0
lines changed

.gitignore

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/.env.local
2+
/.env.local.php
3+
/.env.*.local
4+
/var/
5+
/vendor/
6+
.phpunit
7+
.phpunit.result.cache
8+
phpunit.xml
9+
.php_cs
10+
.php_cs.cache
11+
composer.lock
12+
symfony.lock

.php_cs.dist

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
return Camelot\CsFixer\Config::create()
6+
->addRules(
7+
Camelot\CsFixer\Rules::create()
8+
->risky()
9+
->php71()
10+
)
11+
->addRules([
12+
'@PhpCsFixer:risky' => true,
13+
'@PHP73Migration' => true,
14+
'@PHPUnit60Migration:risky' => true,
15+
'@PHPUnit75Migration:risky' => true,
16+
'declare_strict_types' => true,
17+
'native_function_invocation' => [
18+
'include' => ['@compiler_optimized'],
19+
],
20+
'no_superfluous_phpdoc_tags' => true,
21+
'ordered_class_elements' => true,
22+
'php_unit_strict' => false,
23+
'comment_to_phpdoc' => false,
24+
])
25+
->in('src')
26+
->in('tests')
27+
;

.travis.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
language: php
2+
3+
matrix:
4+
include:
5+
- php: 7.4snapshot
6+
- php: 7.4snapshot
7+
env: COMPOSER_FLAGS="--prefer-lowest"
8+
- php: 7.4snapshot
9+
env: PHPUNIT_FLAGS="--coverage-text --coverage-html coverage/"
10+
- php: nightly
11+
fast_finish: true
12+
allow_failures:
13+
- php: nightly
14+
15+
before_script:
16+
- |
17+
if [[ "$COVERAGE" = true ]] ; then
18+
echo > $HOME/.phpenv/versions/$TRAVIS_PHP_VERSION/etc/conf.d/xdebug.ini
19+
git clone --single-branch --branch=v1.0.6 --depth=1 https://github.com/krakjoe/pcov
20+
cd pcov
21+
phpize
22+
./configure
23+
make clean install
24+
echo "extension=pcov.so" > $HOME/.phpenv/versions/$TRAVIS_PHP_VERSION/etc/conf.d/pcov.ini
25+
cd $TRAVIS_BUILD_DIR
26+
fi
27+
- travis_retry composer self-update
28+
- travis_retry composer update --no-interaction --prefer-dist $COMPOSER_FLAGS
29+
30+
script:
31+
- vendor/bin/phpunit $PHPUNIT_FLAGS
32+
33+
cache:
34+
directories:
35+
- $COMPOSER_CACHE_DIR

composer.json

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"name": "camelot/doctrine-inheritance-mapping",
3+
"description": "Doctrine inheritance mapping library",
4+
"type": "library",
5+
"license": "MIT",
6+
"keywords": ["doctrine", "orm", "inheritance-mapping", "symfony", "symfony-bundle"],
7+
"require": {
8+
"php": "^7.1.3",
9+
"doctrine/annotations": "^1.7",
10+
"doctrine/orm": "^2.5.11"
11+
},
12+
"require-dev": {
13+
"camelot/coding-style": "^2.0",
14+
"doctrine/doctrine-bundle": "^1.6.10",
15+
"friendsofphp/php-cs-fixer": "^2.15",
16+
"phpunit/phpunit": "^8.4",
17+
"ramsey/uuid-doctrine": "^1.5",
18+
"symfony/config": "^4.3",
19+
"symfony/debug-bundle": "^4.3",
20+
"symfony/framework-bundle": "^4.3",
21+
"symfony/http-kernel": "^4.3",
22+
"symfony/phpunit-bridge": "^4.3.4",
23+
"symfony/var-dumper": "^4.3",
24+
"symfony/yaml": "^4.3"
25+
},
26+
"autoload": {
27+
"psr-4": {
28+
"Camelot\\DoctrineInheritanceMapping\\": "src/"
29+
}
30+
},
31+
"autoload-dev": {
32+
"psr-4": {
33+
"Camelot\\DoctrineInheritanceMapping\\Tests\\": "tests/"
34+
}
35+
},
36+
"scripts": {
37+
"lint": "vendor/bin/php-cs-fixer fix --show-progress=dots",
38+
"test": "vendor/bin/phpunit --coverage-text"
39+
}
40+
}

phpunit.xml.dist

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
3+
<!-- https://phpunit.readthedocs.io/en/latest/configuration.html -->
4+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5+
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/8.4/phpunit.xsd"
6+
backupGlobals="false"
7+
colors="true"
8+
bootstrap="vendor/autoload.php"
9+
>
10+
<php>
11+
<ini name="error_reporting" value="-1" />
12+
<server name="SHELL_VERBOSITY" value="-1" />
13+
</php>
14+
15+
<testsuites>
16+
<testsuite name="Project Test Suite">
17+
<directory>tests</directory>
18+
</testsuite>
19+
</testsuites>
20+
21+
<filter>
22+
<whitelist>
23+
<directory>src</directory>
24+
</whitelist>
25+
</filter>
26+
</phpunit>

0 commit comments

Comments
 (0)