All Projects → Codeception → Sample L4 App

Codeception / Sample L4 App

Codeception Laravel Tests

Sample Laravel Application with Codeception tests.

Build Status <- see Travis CI integration

Setup

  • Clone repo
  • Install dependencies:
    • composer install
  • Create databases:
    • touch app/database/database.sqlite
    • touch app/database/testing.sqlite
    • php artisan migrate --seed
    • php artisan migrate --env=testing
  • Server: run php artisan serve
  • Browse to localhost:8000/posts
  • Enter [email protected] as username, and password as the password

To test

Run Codeception, installed via Composer

./vendor/bin/codecept run

Tests

Please check out some good test examples provided.

Functional Tests

Demonstrates testing of CRUD application with

CLI Tests

Demonstrates testing of Artisan commands. See CliHelper to learn how to perform cleanup between tests, and create cutom runArtisan command

API Tests

Demonstrates functional testing of API using REST and Laravel4 modules connected, with

  • partial json inclusion in response
  • GET/POST/PUT/DELETE requests
  • check changes inside database
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].