backend/tests/unit/IngredientsTest.php
//criar, editar e eliminar na DB
criar, editar e eliminar na DB
criar editar e eliminar na DB
function testSavingIngredient()
    {
        $ingrediente = new Ingredients();
        $ingrediente->name = 'alho';
        $ingrediente->stock = 20;
        $ingrediente->save();
        $this->tester->seeInDatabase('ingredients', ['name' => 'alho']);
    }
function testSavingIngredient ( ) { $ ingrediente = new Ingredients ( ) ; $ ingrediente -> name = 'alho' ; $ ingrediente -> stock = 20 ; $ ingrediente -> save ( ) ; $ this -> tester -> seeInDatabase ( 'ingredients' , [ 'name' => 'alho' ] ) ; }
criar, editar e eliminar na DB
criar editar e eliminar na DB