Guest User

Untitled

a guest
Aug 14th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. # ... this sets up db with some data for our tests
  2. my $dbh = DBI->connect("dbi:SQLite:dbname=:memory:");
  3. $dbh->do('create table user (name varchar(100) primary key, age int)');
  4.  
  5. # .... congfigure plugin to point to a :memory: db
  6. set plugins => { DBIC => { foo => { dsn => "dbi:SQLite:dbname=:memory:" } } };
  7.  
  8.  
  9. #Now when you grab a schema object via schema('foo'), this does not refer to
  10. #the db created first via DBI. It will refer to a brand new :memory: db.
  11. #That's my understanding at least. And it's even worse when you want to
  12. #test multiple schemas.
Add Comment
Please, Sign In to add comment