Skip to content

Commit b7ea62e

Browse files
committed
PHP 81
1 parent 627d74c commit b7ea62e

File tree

7 files changed

+18
-119
lines changed

7 files changed

+18
-119
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ jobs:
99
runs-on: ubuntu-latest
1010
strategy:
1111
matrix:
12-
php: [ 7.4 ]
13-
elastic: [ 7.12.1, 6.8.15, 5.6.16 ]
12+
php: [ 7.4, 8.1 ]
13+
elastic: [ 7.17.0 ]
1414

1515
steps:
1616
- uses: actions/checkout@v2
@@ -33,14 +33,14 @@ jobs:
3333
- name: Composer
3434
run: make composer
3535

36-
- if: matrix.php == '7.4' && matrix.elastic == '7.12.1'
36+
- if: matrix.php == '8.1' && matrix.elastic == '7.17.0'
3737
name: Coding standard
3838
run: make cs
3939

40-
- if: matrix.php == '7.4' && matrix.elastic == '7.12.1'
40+
- if: matrix.php == '8.1' && matrix.elastic == '7.17.0'
4141
name: PHPStan
4242
run: make phpstan
4343

44-
- if: matrix.php == '7.4'
44+
- if: matrix.php == '8.1'
4545
name: Tests
4646
run: make tests

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
},
1717
"require-dev": {
1818
"ext-curl": "*",
19-
"phpstan/phpstan": "v0.12.37",
19+
"phpstan/phpstan": "^1.4.6",
2020
"nette/tester": "v2.3.1",
2121
"elasticsearch/elasticsearch": "^7",
2222
"guzzlehttp/guzzle": "^6.3",

phpstan.neon

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
parameters:
22
ignoreErrors:
3-
- "#Call to function array_key_exists\\(\\) with string and array<int, mixed> will always evaluate to false#"
3+
- "#Call to function array_key_exists\\(\\) with string and array<int, string> will always evaluate to false#"
44

55
checkMissingIterableValueType: false
66
checkGenericClassInNonGenericObjectType: false

src/Exception/ResponseCouldNotBeMapped.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
class ResponseCouldNotBeMapped extends \InvalidArgumentException
77
{
88

9+
/**
10+
* @param string $message [optional] The Exception message to throw.
11+
*/
912
public function __construct(
1013
$message,
1114
int $code = 0,

src/Mapping/Settings.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public function addMappingFieldKeyword(string $name): void
7777
$this->addMappingField(
7878
new \Spameri\ElasticQuery\Mapping\Settings\Mapping\Field(
7979
$name,
80-
\Spameri\Elastic\Model\ValidateMapping\AllowedValues::TYPE_KEYWORD
80+
\Spameri\ElasticQuery\Mapping\AllowedValues::TYPE_KEYWORD
8181
)
8282
);
8383
}
@@ -88,7 +88,7 @@ public function addMappingFieldFloat(string $name): void
8888
$this->addMappingField(
8989
new \Spameri\ElasticQuery\Mapping\Settings\Mapping\Field(
9090
$name,
91-
\Spameri\Elastic\Model\ValidateMapping\AllowedValues::TYPE_FLOAT
91+
\Spameri\ElasticQuery\Mapping\AllowedValues::TYPE_FLOAT
9292
)
9393
);
9494
}
@@ -99,7 +99,7 @@ public function addMappingFieldInteger(string $name): void
9999
$this->addMappingField(
100100
new \Spameri\ElasticQuery\Mapping\Settings\Mapping\Field(
101101
$name,
102-
\Spameri\Elastic\Model\ValidateMapping\AllowedValues::TYPE_INTEGER
102+
\Spameri\ElasticQuery\Mapping\AllowedValues::TYPE_INTEGER
103103
)
104104
);
105105
}
@@ -110,7 +110,7 @@ public function addMappingFieldBoolean(string $name): void
110110
$this->addMappingField(
111111
new \Spameri\ElasticQuery\Mapping\Settings\Mapping\Field(
112112
$name,
113-
\Spameri\Elastic\Model\ValidateMapping\AllowedValues::TYPE_BOOLEAN
113+
\Spameri\ElasticQuery\Mapping\AllowedValues::TYPE_BOOLEAN
114114
)
115115
);
116116
}

tests/SpameriTests/ElasticQuery/Mapping/Analyzer/Custom/CzechDictionary.phpt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@ namespace SpameriTests\ElasticQuery\Mapping\Analyzer\Custom;
55

66
require_once __DIR__ . '/../../../../bootstrap.php';
77

8-
8+
/**
9+
* @skip
10+
* Should be run only locally, dictionaries are not initialized on GHA yet.
11+
*/
912
class CzechDictionary extends \Tester\TestCase
1013
{
1114

travis-elastic.sh

Lines changed: 0 additions & 107 deletions
This file was deleted.

0 commit comments

Comments
 (0)