Skip to content

Commit

Permalink
Issue #210 test update (#211)
Browse files Browse the repository at this point in the history
* Initial ci update, determine if core images will work without refactoring source

* github actions script update, move 8.1 from exp to supported; add 8.2 as exp

* Fix coding standards and add 8.2 as supported.

* Correct error

* Coding standards

* stds

* Update CI config

* Update config image

* force file creation

* adding command

* undo prev changes

* updating image

* Move require statement

* Fix coding stds error

* coding stds
  • Loading branch information
nd4p90x authored Mar 10, 2023
1 parent 93cdb5a commit d6c445e
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 15 deletions.
17 changes: 15 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

# PHP CircleCI 2.0 configuration file
#
# Check https://circleci.com/docs/2.0/language-php/ for more details
Expand All @@ -16,6 +17,8 @@ jobs:
- run: sudo apt update
- run: sudo apt install zlib1g-dev
- run: sudo docker-php-ext-install zip
- run: php --version
- run: node --version

- restore_cache:
keys:
Expand Down Expand Up @@ -51,10 +54,20 @@ jobs:
test-php8.0:
<<: *multi-test
docker:
- image: circleci/php:8.0-node
- image: circleci/php:8.0-browsers
test-php8.1:
<<: *multi-test
docker:
- image: cimg/php:8.1-browsers
test-php8.2:
<<: *multi-test
docker:
- image: cimg/php:8.2-browsers
workflows:
version: 2
multi-test:
jobs:
- test-php7.4
- test-php8.0
- test-php8.0
- test-php8.1
- test-php8.2
18 changes: 8 additions & 10 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Set up PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
php-version: '8.1'
coverage: none
tools: cs2pr

Expand All @@ -38,11 +38,8 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
php: ['7.4', '8.0']
php: ['7.4', '8.0', '8.1', '8.2']
experimental: [false]
include:
- php: '8.1'
experimental: true

name: "Lint: PHP ${{ matrix.php }}"
continue-on-error: ${{ matrix.experimental }}
Expand Down Expand Up @@ -76,7 +73,7 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
php: ['7.4', '8.0']
php: ['7.4', '8.0', '8.1', '8.2']
coverage: [false]
experimental: [false]
include:
Expand All @@ -87,11 +84,12 @@ jobs:
- php: '8.0'
coverage: true
experimental: false

# Experimental builds. These are allowed to fail.
- php: '8.1'
coverage: false
experimental: true
coverage: true
experimental: false
- php: '8.2'
coverage: true
experimental: false

name: "Test: PHP ${{ matrix.php }}"

Expand Down
5 changes: 5 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
3.5.1 / 2023-01-31
==================

* Include support for 8.1 * 8.2 (#210)


3.5.0 / 2022-08-17
==================
Expand Down
4 changes: 2 additions & 2 deletions lib/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@
use Segment\Consumer\LibCurl;
use Segment\Consumer\Socket;

require __DIR__ . '/Version.php';

class Client
{
protected Consumer $consumer;
Expand Down Expand Up @@ -110,6 +108,8 @@ private function message(array $msg, string $def = ''): array
*/
private function getDefaultContext(): array
{
require __DIR__ . '/Version.php';

global $SEGMENT_VERSION;

return [
Expand Down
2 changes: 1 addition & 1 deletion lib/Version.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

global $SEGMENT_VERSION;

$SEGMENT_VERSION = '3.5.0';
$SEGMENT_VERSION = '3.5.1';

0 comments on commit d6c445e

Please sign in to comment.