Skip to content

Instantly share code, notes, and snippets.

@andrewhl
Created June 22, 2014 14:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrewhl/ed0e3aeb5190b1e7c122 to your computer and use it in GitHub Desktop.
Save andrewhl/ed0e3aeb5190b1e7c122 to your computer and use it in GitHub Desktop.
Cannot use Auth::loginUsingId(1) in Codeception acceptance/_bootstrap.php file
<?php
Auth::loginUsingId(1);
class_name: AcceptanceTester
modules:
enabled:
- AcceptanceHelper
- Laravel4
- PhpBrowser
- Db
config:
PhpBrowser:
url: 'http://localhost'
Laravel4:
cleanup: false
Db:
populate: true
cleanup: false
actor: Tester
paths:
tests: tests
log: tests/_output
data: tests/_data
helpers: tests/_support
settings:
bootstrap: _bootstrap.php
colors: true
memory_limit: 1024M
modules:
config:
Db:
dsn: 'pgsql:host=localhost;dbname=myapp'
user: 'someuser'
password: 'somepass'
dump: tests/_data/dump.sql
[Illuminate\Database\QueryException]
SQLSTATE[42P01]: Undefined table: 7 ERROR: relation "users" does not exist
LINE 1: select * from "users" where "id" = $1 limit 1
^ (SQL: select * from "users" where "id" = 1 limit 1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment