Last active
November 20, 2020 03:23
-
-
Save GuilhermeManzano/0a8ba2a859fe49f7970de9f6b072c59d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Rule | |
public ExpectedException exception = ExpectedException.none(); | |
@Test | |
public void testLocacao_filmeSemEstoque_3() throws Exception { | |
// cenario | |
LocacaoService service = new LocacaoService(); | |
Usuario usuario = new Usuario("Usuario 1"); | |
Filme filme = new Filme("Filme 1", 0, 5.0); | |
exception.expect(Exception.class); | |
exception.expectMessage("Filme sem estoque"); | |
// açao | |
service.alugarFilme(usuario, filme); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment