Skip to content

Commit ea01898

Browse files
committed
Release v1.0
1 parent 4144d34 commit ea01898

8 files changed

Lines changed: 30 additions & 17 deletions

File tree

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
repoversion=$(shell LANG=C aptitude show php-ease-fluentpdo | grep Version: | awk '{print $$2}')
1+
repoversion=$(shell LANG=C aptitude show php-vitexsoftware-ease-fluentpdo | grep Version: | awk '{print $$2}')
22
nextversion=$(shell echo $(repoversion) | perl -ne 'chomp; print join(".", splice(@{[split/\./,$$_]}, 0, -1), map {++$$_} pop @{[split/\./,$$_]}), "\n";')
33

44
all:

composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
}
99
],
1010
"require": {
11-
"vitexsoftware/ease-core": "dev-master",
12-
"fpdo/fluentpdo": "dev-master",
13-
"robmorgan/phinx": "^0.12.3"
11+
"robmorgan/phinx": "^0.12.3",
12+
"vitexsoftware/ease-core": "^1.1",
13+
"fpdo/fluentpdo": "^2.1"
1414
},
1515
"require-dev": {
1616
"phpunit/phpunit": "^9",

debian/changelog

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
php-ease-fluentpdo (0.2.6) UNRELEASED; urgency=medium
1+
php-vitexsoftware-ease-fluentpdo (1.0) main; urgency=medium
22

33
* Initial release. (Closes: #XXXXXX)
44
* twbootstrap renamed to bootstrap
@@ -15,5 +15,8 @@ php-ease-fluentpdo (0.2.6) UNRELEASED; urgency=medium
1515
* Release v0.2.4
1616
* Merge origin/master
1717
* Update with null columns fixed
18+
* Engine Unit Tests
19+
* Engine Unit Tests
20+
*
1821

19-
-- CyberVitexus <vitex@exiv.jinonice.czf> Mon, 13 Jul 2020 15:22:21 +0200
22+
-- CyberVitexus <vitex@exiv.jinonice.czf> Tue, 11 Aug 2020 12:48:59 +0200

debian/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,5 @@
2020
"conflict": {
2121
"deb/ease-framework": "*"
2222
},
23-
"address": "0.2.6"
23+
"address": "1.0"
2424
}

debian/control

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
` Source: php-vitexsoftware-ease-fluentpdo
1+
Source: php-vitexsoftware-ease-fluentpdo
22
Build-Depends: debhelper (>= 7.0.50~)
33
Section: web
44
Standards-Version: 3.9.8

debian/files

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
php-ease-fluentpdo_0.2.6_all.deb web optional
2-
php-ease-fluentpdo_0.2.6_amd64.buildinfo web optional
1+
php-vitexsoftware-ease-fluentpdo_1.0_amd64.buildinfo web optional
2+
php-vitexsofware-ease-fluentpdo_1.0_all.deb web optional

tests/src/Ease/SQL/EngineTest.php

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,22 @@ class EngineTest extends \PHPUnit\Framework\TestCase {
1515
protected $object;
1616
protected $lastId = null;
1717

18+
private function updateLastId() {
19+
$this->lastId = $this->object->listingQuery()->orderBy('id DESC')->limit(1)->fetchColumn(0);
20+
}
21+
1822
/**
1923
* Sets up the fixture, for example, opens a network connection.
2024
* This method is called before a test is executed.
2125
*/
2226
protected function setUp(): void {
23-
$this->object = new Engine(null, ['myTable' => 'test', 'createColumn' => 'created', 'lastModifiedColumn' => 'updated']);
24-
$this->lastId = $this->object->listingQuery()->orderBy('id DESC')->limit(1)->fetchColumn(0);
27+
$this->object = new Engine(null, [
28+
'myTable' => 'test',
29+
'createColumn' => 'created',
30+
'lastModifiedColumn' => 'updated',
31+
'nameColumn' => 'key'
32+
]);
33+
$this->updateLastId();
2534
}
2635

2736
/**
@@ -57,7 +66,8 @@ public function testConstructor() {
5766
* @covers Ease\SQL\Engine::getRecordName
5867
*/
5968
public function testGetRecordName() {
60-
$this->assertEquals('', $this->object->GetRecordName());
69+
$this->object->loadFromSQL(1);
70+
$this->assertEquals('', $this->object->getRecordName());
6171
}
6272

6373
/**
@@ -120,21 +130,21 @@ public function testGetPdo() {
120130
* @covers Ease\SQL\Engine::getFluentPDO
121131
*/
122132
public function testGetFluentPDO() {
123-
$this->assertEquals('Envms\FluentPDO\Query', $this->object->getFluentPDO());
133+
$this->assertInstanceOf('Envms\FluentPDO\Query', $this->object->getFluentPDO());
124134
}
125135

126136
/**
127137
* @covers Ease\SQL\Engine::listingQuery
128138
*/
129139
public function testListingQuery() {
130-
$this->assertEquals('Envms\FluentPDO\Queries\Select', get_class($this->object->listingQuery()));
140+
$this->assertInstanceOf('Envms\FluentPDO\Queries\Select', $this->object->listingQuery());
131141
}
132142

133143
/**
134144
* @covers Ease\SQL\Engine::getColumnsFromSQL
135145
*/
136146
public function testGetColumnsFromSQL() {
137-
$this->assertEquals('', $this->object->GetColumnsFromSQL(['id']));
147+
$this->assertEquals([2 => ['id' => 2]], $this->object->getColumnsFromSQL(['id'], ['id' => 2], 'id', 'id'));
138148
}
139149

140150
/**
@@ -163,7 +173,7 @@ public function testDbreload() {
163173
*/
164174
public function testDbsync() {
165175
$this->object->setData(['id' => 3, 'key' => 'thrid', 'value' => 'newone']);
166-
$this->assertEquals('', $this->object->dbsync());
176+
$this->assertTrue($this->object->dbsync());
167177
}
168178

169179
/**

tests/test.sqlite

0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)