Example #1
0
 public function testInventoryCreateStockOnLocation()
 {
     $item = $this->newInventory();
     $location = $this->newLocation();
     Lang::shouldReceive('get')->once();
     $item->createStockOnLocation(10, $location);
     $stock = InventoryStock::find(1);
     $this->assertEquals(10, $stock->quantity);
 }
Example #2
0
 public function testInventoryStockNewTransaction()
 {
     $this->newInventoryStock();
     $stock = InventoryStock::find(1);
     $transaction = $stock->newTransaction();
     $this->assertInstanceOf('Stevebauman\\Inventory\\Interfaces\\StateableInterface', $transaction);
 }