Skip to content

Commit 5058696

Browse files
committed
This package will be maintained for PHP 7.x. only.
1 parent f7b261d commit 5058696

File tree

5 files changed

+26
-58
lines changed

5 files changed

+26
-58
lines changed

.travis.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
language: php
22
php:
3-
- '5.4'
4-
- '5.5'
5-
- '5.6'
63
- '7.0'
7-
- hhvm
4+
- '7.1'
85
- nightly
96

107
install:

.version

Lines changed: 0 additions & 1 deletion
This file was deleted.

build.xml

Lines changed: 4 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,50 +1,12 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<project name="php-mysql-data-layer" default="build" basedir=".">
3-
<taskdef name="readSemanticVersion" classname="vendor.setbased.phing-extensions.src.Task.ReadSemanticVersionTask"/>
4-
<property name="VERSION" value="0.0.0"/>
5-
2+
<project name="php-erd-concepts" default="build" basedir=".">
63
<target name="build">
74
<echo message="noting to do."/>
85
</target>
96

10-
<!-- Merges the current branch with a remote branch -->
11-
<target name="git-merge">
12-
<exec command="git rev-parse --abbrev-ref HEAD" outputProperty="CURRENT_BRANCH"/>
13-
<input message="Your current branch is '${CURRENT_BRANCH}'. Remote branch: " propertyName="BRANCH"/>
14-
<gitbranch branchname="temp" repository="."/>
15-
<gitcheckout repository="." branchname="temp"/>
16-
<gitpull repository="." refspec="${BRANCH}" quiet="false"/>
17-
<gitcheckout repository="." branchname="${CURRENT_BRANCH}"/>
18-
<gitmerge repository="." remote="temp"/>
19-
<gitbranch branchname="temp" repository="." delete="true"/>
20-
</target>
21-
22-
<!-- Merges the current branch with a remote branch in two steps: step 1 -->
23-
<target name="git-merge1">
24-
<exec command="git rev-parse --abbrev-ref HEAD" outputProperty="CURRENT_BRANCH" checkreturn="true"/>
25-
<exec command="git fetch -p" passthru="true" checkreturn="true"/>
26-
<input message="Your current branch is '${CURRENT_BRANCH}'. Remote branch: " propertyName="BRANCH"/>
27-
<gitbranch branchname="temp" repository="."/>
28-
<gitcheckout repository="." branchname="temp"/>
29-
<gitpull repository="." refspec="${BRANCH}" quiet="false"/>
30-
</target>
31-
32-
<!-- Merges the current branch with a remote branch in two steps: step 2 -->
33-
<target name="git-merge2">
34-
<exec command="git rev-parse --abbrev-ref HEAD" outputProperty="CURRENT_BRANCH" checkreturn="true"/>
35-
<input message="Your current branch is '${CURRENT_BRANCH}'. Branch: " propertyName="BRANCH"/>
36-
<gitcheckout repository="." branchname="${BRANCH}"/>
37-
<gitmerge repository="." remote="temp"/>
38-
<gitbranch branchname="temp" repository="." delete="true"/>
39-
</target>
40-
41-
<!-- Creates a new version/release. -->
42-
<target name="version">
43-
<readSemanticVersion file=".version" versionProperty="VERSION"/>
44-
<gitcommit repository="." message="Release: ${VERSION}" allFiles="true"/>
45-
<gitpush repository="."/>
46-
<gittag repository="." name="${VERSION}"/>
47-
<gitpush repository="." refspec="${VERSION}" quiet="false"/>
7+
<!-- Run composer update and executes various other updates -->
8+
<target name="update">
9+
<exec command="composer update --prefer-source" checkreturn="true" passthru="true"/>
4810
</target>
4911

5012
<!-- Runs all unit tests -->

composer.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,22 @@
99
"fix"
1010
],
1111
"require": {
12-
"php": ">=5.4.0"
12+
"php": ">=7.0.0"
1313
},
1414
"require-dev": {
15-
"phpunit/phpunit": ">=4.0",
16-
"setbased/phing-extensions": "2.*"
15+
"phpunit/phpunit": "^6.0.0",
16+
"phing/phing": "^2.0.0"
1717
},
1818
"autoload": {
1919
"psr-4": {
2020
"SetBased\\ErdConcepts\\": "src"
2121
}
2222
},
23+
"autoload-dev": {
24+
"psr-4": {
25+
"SetBased\\ErdConcepts\\": "src"
26+
}
27+
},
2328
"config": {
2429
"bin-dir": "bin"
2530
}

test/ErdConceptMySQLTest.php

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
11
<?php
22
//----------------------------------------------------------------------------------------------------------------------
3+
namespace SetBased\ErdConcepts\Test;
4+
5+
use PHPUnit\Framework\TestCase;
36
use SetBased\ErdConcepts\MySqlFix;
47

5-
//----------------------------------------------------------------------------------------------------------------------
6-
class ErdConceptMySQLTest extends PHPUnit_Framework_TestCase
8+
/**
9+
* Unit test for class MySqlFix.
10+
*/
11+
class ErdConceptMySQLTest extends TestCase
712
{
813
//--------------------------------------------------------------------------------------------------------------------
914
/**
@@ -15,7 +20,7 @@ public function testColumns1()
1520
$expected = file_get_contents(realpath(__DIR__).'/template/quoted/column.ddl');
1621

1722
$result = MySqlFix::fixColumnComments($source);
18-
$this->assertEquals($expected, $result);
23+
self::assertEquals($expected, $result);
1924
}
2025

2126
//--------------------------------------------------------------------------------------------------------------------
@@ -28,7 +33,7 @@ public function testColumns2()
2833
$expected = file_get_contents(realpath(__DIR__).'/template/unquoted/column.ddl');
2934

3035
$result = MySqlFix::fixColumnComments($source);
31-
$this->assertEquals($expected, $result);
36+
self::assertEquals($expected, $result);
3237
}
3338

3439
//--------------------------------------------------------------------------------------------------------------------
@@ -41,7 +46,7 @@ public function testIndex1()
4146
$expected = file_get_contents(realpath(__DIR__).'/template/quoted/index.ddl');
4247

4348
$result = MySqlFix::fixIndexComments($source);
44-
$this->assertEquals($expected, $result);
49+
self::assertEquals($expected, $result);
4550
}
4651

4752
//--------------------------------------------------------------------------------------------------------------------
@@ -54,7 +59,7 @@ public function testIndex2()
5459
$expected = file_get_contents(realpath(__DIR__).'/template/unquoted/index.ddl');
5560

5661
$result = MySqlFix::fixIndexComments($source);
57-
$this->assertEquals($expected, $result);
62+
self::assertEquals($expected, $result);
5863
}
5964

6065
//--------------------------------------------------------------------------------------------------------------------
@@ -67,7 +72,7 @@ public function testTables1()
6772
$expected = file_get_contents(realpath(__DIR__).'/template/quoted/table.ddl');
6873

6974
$result = MySqlFix::fixTableComments($source);
70-
$this->assertEquals($expected, $result);
75+
self::assertEquals($expected, $result);
7176
}
7277

7378
//--------------------------------------------------------------------------------------------------------------------
@@ -80,7 +85,7 @@ public function testTables2()
8085
$expected = file_get_contents(realpath(__DIR__).'/template/unquoted/table.ddl');
8186

8287
$result = MySqlFix::fixTableComments($source);
83-
$this->assertEquals($expected, $result);
88+
self::assertEquals($expected, $result);
8489
}
8590

8691
//--------------------------------------------------------------------------------------------------------------------

0 commit comments

Comments
 (0)