Skip to content

Commit

Permalink
Agrego tests choque con moneda y mosquito
Browse files Browse the repository at this point in the history
  • Loading branch information
Lucard02 committed Nov 14, 2024
1 parent 9d61784 commit a32d7f6
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion pruebas.wtest
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,22 @@ import example.*

describe "Tests de los obstaculos" {

test "La puntuación aumenta de 0 a 8 al recoger una moneda" {
dinosaurio.puntos(0)
generadorDeMonedas.generar()
var moneda = new Moneda(image = "moneda.png")
moneda.teChocoElDino()
assert.equals(8,dinosaurio.puntos())
}

test "La puntuación disminuye de 10 a 6 al chocar con mosquito" {
dinosaurio.puntos(10)
generadorDePeras.generar()
var pera = new Pera(image = "mosquito.png")
pera.teChocoElDino()
assert.equals(6,dinosaurio.puntos())
}

test "Cuando el dino choca con *cactus1*, desaparecen todos los visuales" {
cactus1.teChocoElDino()
var verificador
Expand All @@ -24,5 +40,4 @@ describe "Tests de los obstaculos" {
}
assert.that(verificador)
}

}

0 comments on commit a32d7f6

Please sign in to comment.