Skip to content

Commit ce21ae2

Browse files
Laravel 11.x Shift (alexjustesen#1389)
Co-authored-by: Shift <[email protected]>
1 parent 4ff86a9 commit ce21ae2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+1948
-2998
lines changed

.env.example

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,20 @@ APP_NAME="Speedtest Tracker"
22
APP_ENV=local
33
APP_KEY=
44
APP_DEBUG=false
5+
APP_TIMEZONE=UTC
56
APP_URL=http://localhost
67

8+
APP_LOCALE=en
9+
APP_FALLBACK_LOCALE=en
10+
APP_FAKER_LOCALE=en_US
11+
12+
APP_MAINTENANCE_DRIVER=file
13+
APP_MAINTENANCE_STORE=database
14+
15+
BCRYPT_ROUNDS=12
16+
717
LOG_CHANNEL=stack
18+
LOG_STACK=single
819
LOG_DEPRECATIONS_CHANNEL=null
920
LOG_LEVEL=debug
1021

@@ -15,12 +26,15 @@ DB_DATABASE=speedtest_tracker
1526
DB_USERNAME=
1627
DB_PASSWORD=
1728

18-
BROADCAST_DRIVER=log
19-
CACHE_DRIVER=database
29+
BROADCAST_CONNECTION=log
30+
CACHE_STORE=database
2031
FILESYSTEM_DISK=local
2132
QUEUE_CONNECTION=database
2233
SESSION_DRIVER=database
2334
SESSION_LIFETIME=120
35+
SESSION_ENCRYPT=false
36+
SESSION_PATH=/
37+
SESSION_DOMAIN=null
2438

2539
MAIL_MAILER=smtp
2640
MAIL_HOST=mailhog

.env.testing

Lines changed: 25 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,41 @@
11
APP_NAME="Speedtest Tracker"
22
APP_ENV=local
3-
APP_KEY=base64:Tx3xYzxoL/5LmKHYr9QXlbnhTDVE1GK5T7tzxpovHaY=
3+
APP_KEY=
44
APP_DEBUG=true
55
APP_URL=http://localhost
66

7+
APP_LOCALE=en
8+
APP_FALLBACK_LOCALE=en
9+
APP_FAKER_LOCALE=en_US
10+
11+
APP_MAINTENANCE_DRIVER=file
12+
APP_MAINTENANCE_STORE=database
13+
14+
BCRYPT_ROUNDS=12
15+
716
LOG_CHANNEL=stack
817
LOG_DEPRECATIONS_CHANNEL=null
918
LOG_LEVEL=debug
1019

11-
DB_CONNECTION=mysql
12-
DB_HOST=127.0.0.1
13-
DB_PORT=3306
14-
DB_DATABASE=testing
15-
DB_USERNAME=root
16-
DB_PASSWORD=
20+
DB_CONNECTION=sqlite
21+
# DB_HOST=127.0.0.1
22+
# DB_PORT=3306
23+
# DB_DATABASE=testing
24+
# DB_USERNAME=root
25+
# DB_PASSWORD=
1726

18-
BROADCAST_DRIVER=log
19-
CACHE_DRIVER=database
27+
BROADCAST_CONNECTION=log
28+
CACHE_STORE=file
2029
FILESYSTEM_DISK=local
21-
QUEUE_CONNECTION=database
22-
SESSION_DRIVER=database
30+
QUEUE_CONNECTION=sync
31+
SESSION_DRIVER=file
2332
SESSION_LIFETIME=1440
2433

34+
MEMCACHED_HOST=127.0.0.1
35+
36+
REDIS_HOST=127.0.0.1
37+
REDIS_PASSWORD=null
38+
2539
MAIL_MAILER=smtp
2640
MAIL_HOST=mailhog
2741
MAIL_PORT=1025

.github/workflows/cd.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ jobs:
1919
packages: write
2020

2121
steps:
22-
- name: Checkout repository
23-
uses: actions/checkout@v3
22+
- name: Checkout
23+
uses: actions/checkout@v4
2424

2525
- name: Set up QEMU
2626
uses: docker/setup-qemu-action@v3

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ jobs:
1717
packages: write
1818

1919
steps:
20-
- name: Checkout repository
21-
uses: actions/checkout@v3
20+
- name: Checkout
21+
uses: actions/checkout@v4
2222

2323
- name: Set up QEMU
2424
uses: docker/setup-qemu-action@v3

.github/workflows/tests.yml

Lines changed: 15 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -12,77 +12,48 @@ on:
1212
jobs:
1313
lint:
1414
runs-on: ubuntu-22.04
15-
1615
steps:
17-
- uses: actions/checkout@v3
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
1819
- name: "duster"
1920
uses: tighten/duster-action@v2
2021
with:
2122
args: lint --using=pint -v
2223

2324
test:
2425
needs: [lint] # needs lint job to pass first
25-
2626
runs-on: ubuntu-22.04
27-
28-
services:
29-
mysql:
30-
image: mysql:8.0
31-
env:
32-
MYSQL_ALLOW_EMPTY_PASSWORD: yes
33-
MYSQL_DATABASE: testing
34-
ports:
35-
- 3306:3306
36-
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
37-
3827
steps:
3928
- name: Checkout
40-
uses: actions/checkout@v3
29+
uses: actions/checkout@v4
4130

4231
- name: Setup PHP
4332
uses: shivammathur/setup-php@v2
4433
with:
4534
php-version: '8.3'
35+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv
36+
coverage: none
4637

4738
- name: Prepare the environment
4839
run: cp .env.testing .env
4940

50-
- name: Get composer cache directory
51-
id: composer-cache
52-
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
53-
54-
- name: Setup composer cache
55-
uses: actions/cache@v4
56-
with:
57-
path: ${{ steps.composer-cache.outputs.dir }}
58-
key: ${{ runner.os }}-composer-${{ hashFiles('composer.lock') }}
59-
restore-keys: ${{ runner.os }}-composer-
60-
6141
- name: Install composer dependencies
62-
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
42+
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress
6343

6444
- name: Install npm dependencies and build assets
6545
run: npm ci && npm run build
6646

67-
- name: Directory permissions
47+
- name: Generate an application key
48+
run: php artisan key:generate
49+
50+
- name: Directory Permissions
6851
run: chmod -R 777 storage bootstrap/cache
6952

70-
- name: Test application install
71-
run: php artisan app:install --force
72-
env:
73-
DB_CONNECTION: mysql
74-
DB_HOST: 127.0.0.1
75-
DB_PORT: ${{ job.services.mysql.ports['3306'] }}
76-
DB_DATABASE: testing
77-
DB_USERNAME: root
78-
DB_PASSWORD: null
53+
- name: Create SQLite database
54+
run: |
55+
mkdir -p database
56+
touch database/database.sqlite
7957
8058
- name: Run tests
8159
run: php artisan test
82-
env:
83-
DB_CONNECTION: mysql
84-
DB_HOST: 127.0.0.1
85-
DB_PORT: ${{ job.services.mysql.ports['3306'] }}
86-
DB_DATABASE: testing
87-
DB_USERNAME: root
88-
DB_PASSWORD: null

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
1+
/.phpunit.cache
12
/node_modules
23
/public/hot
34
/public/storage
45
/storage/*.key
56
/vendor
67
.env
78
.env.backup
9+
.phpunit.result.cache
810
Homestead.json
911
Homestead.yaml
1012
auth.json

0 commit comments

Comments
 (0)