Example #1
0
 public function run()
 {
     Eloquent::unguard();
     DB::table('users')->truncate();
     User::create(array('firstname' => 'Kevin', 'lastname' => 'Wennemuth', 'username' => 'feffi', 'email' => '*****@*****.**', 'password' => Hash::make('test')));
     User::create(array('firstname' => 'John', 'lastname' => 'Tester', 'username' => 'john', 'email' => '*****@*****.**', 'password' => Hash::make('john')));
 }
Example #2
0
 /**
  * @test
  * @large
  */
 public function testHasTracks()
 {
     $user = User::find(2);
     $this->assertTrue($user->hasTracks(array(1, 2)));
     $this->assertFalse($user->hasTracks(array(3)));
     $this->assertFalse($user->hasTracks(array(1, 3)));
     $this->assertFalse($user->hasTracks(array(2, 3)));
     $this->assertFalse($user->hasTracks(array(1, 2, 3)));
     $this->assertFalse($user->hasTracks(array()));
 }