Skip to content

Commit

Permalink
feat: initial laravel 9 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
divine committed Feb 6, 2022
1 parent 6cdd309 commit d02a46c
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 26 deletions.
23 changes: 7 additions & 16 deletions .github/workflows/build-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,14 @@ jobs:
strategy:
matrix:
include:
- { os: ubuntu-latest, php: 7.2, mongodb: 3.6, experimental: true }
- { os: ubuntu-latest, php: 7.2, mongodb: '4.0', experimental: true }
- { os: ubuntu-latest, php: 7.2, mongodb: 4.2, experimental: true }
- { os: ubuntu-latest, php: 7.2, mongodb: 4.4, experimental: true }
- { os: ubuntu-latest, php: 7.3, mongodb: 3.6, experimental: false }
- { os: ubuntu-latest, php: 7.3, mongodb: '4.0', experimental: false }
- { os: ubuntu-latest, php: 7.3, mongodb: 4.2, experimental: false }
- { os: ubuntu-latest, php: 7.3, mongodb: 4.4, experimental: false }
- { os: ubuntu-latest, php: 7.4, mongodb: 3.6, experimental: false }
- { os: ubuntu-latest, php: 7.4, mongodb: '4.0', experimental: false }
- { os: ubuntu-latest, php: 7.4, mongodb: 4.2, experimental: false }
- { os: ubuntu-latest, php: 7.4, mongodb: 4.4, experimental: false }
- { os: ubuntu-latest, php: 8.0, mongodb: '4.0', experimental: false }
- { os: ubuntu-latest, php: 8.0, mongodb: 4.2, experimental: false }
- { os: ubuntu-latest, php: 8.0, mongodb: 4.4, experimental: false }
- { os: ubuntu-latest, php: 8.0, mongodb: '5.0', experimental: false }
- { os: ubuntu-latest, php: 8.1, mongodb: '4.0', experimental: false }
- { os: ubuntu-latest, php: 8.1, mongodb: 4.2, experimental: false }
- { os: ubuntu-latest, php: 8.1, mongodb: 4.4, experimental: false }
- { os: ubuntu-latest, php: 8.1, mongodb: '5.0', experimental: false }
services:
mongo:
image: mongo:${{ matrix.mongodb }}
Expand Down Expand Up @@ -78,22 +73,18 @@ jobs:
env:
DEBUG: ${{secrets.DEBUG}}
- name: Download Composer cache dependencies from cache
if: (!startsWith(matrix.php, '7.2'))
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
- name: Cache Composer dependencies
if: (!startsWith(matrix.php, '7.2'))
uses: actions/cache@v1
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ matrix.os }}-composer-${{ hashFiles('**/composer.json') }}
restore-keys: ${{ matrix.os }}-composer-
- name: Install dependencies
if: (!startsWith(matrix.php, '7.2'))
run: |
composer install --no-interaction
- name: Run tests
if: (!startsWith(matrix.php, '7.2'))
run: |
./vendor/bin/phpunit --coverage-clover coverage.xml
env:
Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ All notable changes to this project will be documented in this file.

## [Unreleased]

### Added
- Compatibility with Laravel 9.x [#](https://github.com/jenssegers/laravel-mongodb/pull/) by [@divine](https://github.com/divine).

## [3.8.4] - 2021-05-27

### Fixed
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ Make sure you have the MongoDB PHP driver installed. You can find installation i

Laravel | Package | Maintained
:---------|:---------------|:----------
9.x | 3.9.x | :white_check_mark:
8.x | 3.8.x | :white_check_mark:
7.x | 3.7.x | :x:
6.x | 3.6.x | :white_check_mark:
Expand Down
20 changes: 11 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@
],
"license": "MIT",
"require": {
"illuminate/support": "^8.0",
"illuminate/container": "^8.0",
"illuminate/database": "^8.0",
"illuminate/events": "^8.0",
"mongodb/mongodb": "^1.6"
"illuminate/support": "9.x-dev",
"illuminate/container": "9.x-dev",
"illuminate/database": "9.x-dev",
"illuminate/events": "9.x-dev",
"mongodb/mongodb": "^1.11"
},
"require-dev": {
"phpunit/phpunit": "^9.0",
"orchestra/testbench": "^6.0",
"phpunit/phpunit": "^9.5.8",
"orchestra/testbench": "7.x-dev",
"mockery/mockery": "^1.3.1",
"doctrine/dbal": "^2.6"
"doctrine/dbal": "^2.13.3|^3.1.4"
},
"autoload": {
"psr-4": {
Expand All @@ -54,5 +54,7 @@
"Jenssegers\\Mongodb\\MongodbQueueServiceProvider"
]
}
}
},
"minimum-stability": "dev",
"prefer-stable": true
}
2 changes: 1 addition & 1 deletion src/Query/Builder.php
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@ public function whereAll($column, array $values, $boolean = 'and', $not = false)
/**
* @inheritdoc
*/
public function whereBetween($column, array $values, $boolean = 'and', $not = false)
public function whereBetween($column, iterable $values, $boolean = 'and', $not = false)
{
$type = 'between';

Expand Down

0 comments on commit d02a46c

Please sign in to comment.