https://github.com/natthasath/demo-laravel-breeze-testing
Laravel Testing involves using Laravel's built-in testing features, like PHPUnit, to write tests for Laravel applications. It includes unit tests, feature tests, and integration tests to ensure the functionality, performance, and reliability of Laravel applications.
https://github.com/natthasath/demo-laravel-breeze-testing
10x breeze factories laravel php seeder tdd test
Last synced: 7 months ago
JSON representation
Laravel Testing involves using Laravel's built-in testing features, like PHPUnit, to write tests for Laravel applications. It includes unit tests, feature tests, and integration tests to ensure the functionality, performance, and reliability of Laravel applications.
- Host: GitHub
- URL: https://github.com/natthasath/demo-laravel-breeze-testing
- Owner: natthasath
- Created: 2024-06-20T06:28:21.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-06-20T06:54:41.000Z (over 1 year ago)
- Last Synced: 2025-02-21T23:21:55.906Z (8 months ago)
- Topics: 10x, breeze, factories, laravel, php, seeder, tdd, test
- Language: PHP
- Homepage: https://laravel.com/docs/master/testing
- Size: 117 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 🎉 DEMO Laravel Breeze TDD
Laravel Testing involves using Laravel's built-in testing features, like PHPUnit, to write tests for Laravel applications. It includes unit tests, feature tests, and integration tests to ensure the functionality, performance, and reliability of Laravel applications.


### 🚀 Setup
- Create Project
```shell
composer create-project laravel/laravel example-app
```- Install Package
```shell
composer require laravel/breeze --dev
```- Configure Environment
```shell
cp .env.example .env
```- Migrate
```
php artisan breeze:install
php artisan migrate
npm install
npm run dev
```- Generate Mailable
```
php artisan make:mail WelcomeEmail --markdown=emails.welcome
php artisan make:controller SendmailController
```- Configure Email
```
MAIL_MAILER=smtp
MAIL_HOST=smtp.example.com
MAIL_PORT=587
MAIL_USERNAME=email@example.com
MAIL_PASSWORD=password
MAIL_ENCRYPTION=tls
MAIL_FROM_ADDRESS=noreply@example.com
MAIL_FROM_NAME="${APP_NAME}"
```- Custom Component
```
php artisan vendor:publish --tag=laravel-mail
```- Install PHPUnit
```
composer require --dev phpunit/phpunit
```- Create Test for Mailable
```
php artisan make:test SendmailTest
```- Run Test
```
php artisan test
```- Create Factories
```
php artisan make:factory UserFactory --model=User
```- Run Seeder
```
php artisan db:seed
php artisan migrate --seed
```### 🏆 Run
- [http://localhost:8000/](http://localhost:8000/) username : `admin` password : `admin`
```shell
php artisan serve
```