Skip to content

Commit 355a0b2

Browse files
authored
Merge pull request #432 from Art4/430-redmine-50104-and-50010
Run behat tests with Redmine 5.1.4 and 5.0.10
2 parents 5e0f1cb + 21d8c19 commit 355a0b2

File tree

6 files changed

+40
-18
lines changed

6 files changed

+40
-18
lines changed

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1111

1212
- New class `Redmine\Http\HttpFactory` to create `Redmine\Http\Request` and `Redmine\Http\Response` instances.
1313

14+
### Changed
15+
16+
- Behaviour-driven tests are run against Redmine 5.1.4, 5.0.10 and 4.2.10.
17+
1418
### Deprecated
1519

1620
- `Redmine\Client\Client::requestGet()` is deprecated, use `\Redmine\Client\Client::request()` instead.

composer.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"name": "kbsali/redmine-api",
3+
"version": "v2.7.0",
34
"type": "library",
45
"description": "Redmine API client",
56
"homepage": "https://github.com/kbsali/php-redmine-api",
@@ -52,8 +53,8 @@
5253
"scripts": {
5354
"bdt": [
5455
"Composer\\Config::disableProcessTimeout",
55-
"@behat --format=progress --suite=redmine_50103",
56-
"@behat --format=progress --suite=redmine_50009",
56+
"@behat --format=progress --suite=redmine_50104",
57+
"@behat --format=progress --suite=redmine_50010",
5758
"@behat --format=progress --suite=redmine_40210"
5859
],
5960
"behat": "behat --config tests/Behat/behat.yml",

docker-compose.yml

+9-9
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ services:
1111
- ./:/var/www/project/ # Location of the project for php-fpm. Note this should be the same for NGINX.*
1212

1313
redmine-dev:
14-
image: redmine:5.1.3
14+
image: redmine:5.1.4
1515
user: "1000:1000"
1616
ports:
1717
- "3000:3000"
@@ -25,29 +25,29 @@ services:
2525
# Make sure the following services are configured in:
2626
# - /tests/Behat/behat.yml
2727

28-
redmine-50103:
29-
image: redmine:5.1.3
28+
redmine-50104:
29+
image: redmine:5.1.4
3030
user: "1000:1000"
3131
ports:
3232
- "5103:3000"
3333
environment:
3434
REDMINE_SECRET_KEY_BASE: supersecretkey
3535
REDMINE_PLUGINS_MIGRATE: true
3636
volumes:
37-
- ./.docker/redmine-50103_data/files:/usr/src/redmine/files
38-
- ./.docker/redmine-50103_data/sqlite:/usr/src/redmine/sqlite
37+
- ./.docker/redmine-50104_data/files:/usr/src/redmine/files
38+
- ./.docker/redmine-50104_data/sqlite:/usr/src/redmine/sqlite
3939

40-
redmine-50009:
41-
image: redmine:5.0.9
40+
redmine-50010:
41+
image: redmine:5.0.10
4242
user: "1000:1000"
4343
ports:
4444
- "5009:3000"
4545
environment:
4646
REDMINE_SECRET_KEY_BASE: supersecretkey
4747
REDMINE_PLUGINS_MIGRATE: true
4848
volumes:
49-
- ./.docker/redmine-50009_data/files:/usr/src/redmine/files
50-
- ./.docker/redmine-50009_data/sqlite:/usr/src/redmine/sqlite
49+
- ./.docker/redmine-50010_data/files:/usr/src/redmine/files
50+
- ./.docker/redmine-50010_data/sqlite:/usr/src/redmine/sqlite
5151

5252
redmine-40210:
5353
# Redmine 4.2.11 is not available on Docker Hub

tests/Behat/README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,13 @@ you can use the `behat` command directly:
2222

2323
```bash
2424
# test only a specific redmine version
25-
docker compose exec php composer behat -- --suite=redmine_50103
25+
docker compose exec php composer behat -- --suite=redmine_50104
2626
# test only specific endpoints
2727
docker compose exec php composer behat -- --tags=issue,group
2828
# test only specific endpoints on a specific redmine version
29-
docker compose exec php composer behat -- --suite=redmine_50103 --tags=issue,group
29+
docker compose exec php composer behat -- --suite=redmine_50104 --tags=issue,group
3030
# test only a specific redmine version and format the output as `progress` (default is `pretty`)
31-
docker compose exec php composer behat -- --suite=redmine_50103 --format=progress
31+
docker compose exec php composer behat -- --suite=redmine_50104 --format=progress
3232
```
3333

3434
## Redmine version specific features

tests/Behat/behat.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
default:
22
suites:
3-
redmine_50103:
3+
redmine_50104:
44
paths:
55
- '%paths.base%/features'
66
contexts:
77
- Redmine\Tests\Behat\Bootstrap\FeatureContext:
8-
redmineVersion: '5.1.3'
9-
redmine_50009:
8+
redmineVersion: '5.1.4'
9+
redmine_50010:
1010
paths:
1111
- '%paths.base%/features'
1212
contexts:
1313
- Redmine\Tests\Behat\Bootstrap\FeatureContext:
14-
redmineVersion: '5.0.9'
14+
redmineVersion: '5.0.10'
1515
redmine_40210:
1616
paths:
1717
- '%paths.base%/features'

tests/RedmineExtension/RedmineVersion.php

+17
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,14 @@
66

77
enum RedmineVersion: string
88
{
9+
/**
10+
* Redmine 5.1.4
11+
*
12+
* @link https://www.redmine.org/versions/197
13+
* @link https://www.redmine.org/projects/redmine/wiki/Changelog_5_1#514-2024-11-03
14+
*/
15+
case V5_1_4 = '5.1.4';
16+
917
/**
1018
* Redmine 5.1.3
1119
*
@@ -47,6 +55,15 @@ enum RedmineVersion: string
4755

4856
case V5_0_9 = '5.0.9';
4957

58+
/**
59+
* Redmine 5.0.10
60+
*
61+
* @link https://www.redmine.org/versions/196
62+
* @link https://www.redmine.org/projects/redmine/wiki/Changelog_5_0#5010-2024-11-03
63+
*/
64+
65+
case V5_0_10 = '5.0.10';
66+
5067
/**
5168
* Redmine 5.0.8
5269
*

0 commit comments

Comments
 (0)