-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1474 from Program-AR/challengeContandoManic
Mañic contando astros
- Loading branch information
Showing
16 changed files
with
319 additions
and
8 deletions.
There are no files selected for viewing
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
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
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
110 changes: 110 additions & 0 deletions
110
tests/integration/desafios/ContandoDeNuevoManic-test.js
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
import { moduloActividad, actividadTest } from '../../helpers/actividadTest'; | ||
|
||
const nombre = "ContandoDeNuevoManic"; | ||
|
||
moduloActividad(nombre, () => { | ||
|
||
actividadTest(nombre, { | ||
solucion: `<?xml version="1.0" encoding="UTF-8"?> | ||
<xml xmlns="http://www.w3.org/1999/xhtml"> | ||
<block type="al_empezar_a_ejecutar" id="3" deletable="false" movable="false" editable="false" x="0" y="0"> | ||
<statement name="program"> | ||
<block type="Repetir" id="4" inline="true"> | ||
<value name="count"> | ||
<block type="math_number" id="5"> | ||
<field name="NUM">4</field> | ||
</block> | ||
</value> | ||
<statement name="block"> | ||
<block type="procedures_callnoreturn" id="6"> | ||
<mutation name="Contar astros de columna" /> | ||
<next> | ||
<block type="procedures_callnoreturn" id="7"> | ||
<mutation name="Volver al inicio" /> | ||
<next> | ||
<block type="SiguienteColumna" id="8" /> | ||
</next> | ||
</block> | ||
</next> | ||
</block> | ||
</statement> | ||
<next> | ||
<block type="procedures_callnoreturn" id="37"> | ||
<mutation name="Contar astros de columna" /> | ||
</block> | ||
</next> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="9" x="280" y="35"> | ||
<mutation /> | ||
<field name="NAME">Volver al inicio</field> | ||
<statement name="STACK"> | ||
<block type="hasta" id="10" inline="true"> | ||
<value name="condition"> | ||
<block type="EstoySobreElInicioManic" id="11" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="MoverACasillaArriba" id="12" /> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="13" x="11" y="201"> | ||
<mutation /> | ||
<field name="NAME">Contar astros de columna</field> | ||
<statement name="STACK"> | ||
<block type="Repetir" id="14" inline="true"> | ||
<value name="count"> | ||
<block type="LargoColumnaActual" id="15" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="MoverACasillaAbajo" id="16"> | ||
<next> | ||
<block type="procedures_callnoreturn" id="17"> | ||
<mutation name="Contar planeta si hay" /> | ||
<next> | ||
<block type="procedures_callnoreturn" id="18"> | ||
<mutation name="Contar estrella si hay" /> | ||
</block> | ||
</next> | ||
</block> | ||
</next> | ||
</block> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="19" x="319" y="281"> | ||
<mutation /> | ||
<field name="NAME">Contar planeta si hay</field> | ||
<statement name="STACK"> | ||
<block type="si" id="20" inline="true"> | ||
<value name="condition"> | ||
<block type="TocandoPlaneta" id="21" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="ContarPlaneta" id="22" /> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="23" x="47" y="393"> | ||
<mutation /> | ||
<field name="NAME">Contar estrella si hay</field> | ||
<statement name="STACK"> | ||
<block type="si" id="24" inline="true"> | ||
<value name="condition"> | ||
<block type="TocandoEstrellaManic" id="25" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="ContarEstrella" id="26" /> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
</xml>`, | ||
|
||
}); | ||
|
||
}); |
110 changes: 110 additions & 0 deletions
110
tests/integration/desafios/ContandoPlanetasYEstrellas-test.js
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
import { moduloActividad, actividadTest } from '../../helpers/actividadTest'; | ||
|
||
const nombre = 'ContandoPlanetasYEstrellas'; | ||
|
||
moduloActividad(nombre, () => { | ||
|
||
actividadTest(nombre, { | ||
solucion: `<?xml version="1.0" encoding="UTF-8"?> | ||
<xml xmlns="http://www.w3.org/1999/xhtml"> | ||
<block type="al_empezar_a_ejecutar" id="1" deletable="false" movable="false" editable="false" x="0" y="0"> | ||
<statement name="program"> | ||
<block type="Repetir" id="68" inline="true"> | ||
<value name="count"> | ||
<block type="math_number" id="69"> | ||
<field name="NUM">4</field> | ||
</block> | ||
</value> | ||
<statement name="block"> | ||
<block type="procedures_callnoreturn" id="81"> | ||
<mutation name="Contar astros de columna" /> | ||
<next> | ||
<block type="procedures_callnoreturn" id="87"> | ||
<mutation name="Volver al inicio" /> | ||
<next> | ||
<block type="SiguienteColumna" id="93" /> | ||
</next> | ||
</block> | ||
</next> | ||
</block> | ||
</statement> | ||
<next> | ||
<block type="procedures_callnoreturn" id="108"> | ||
<mutation name="Contar astros de columna" /> | ||
</block> | ||
</next> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="53" x="277" y="15"> | ||
<mutation /> | ||
<field name="NAME">Contar astros de columna</field> | ||
<statement name="STACK"> | ||
<block type="hasta" id="114" inline="true"> | ||
<value name="condition"> | ||
<block type="EstoySobreElFinalManic" id="129" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="MoverACasillaAbajo" id="146"> | ||
<next> | ||
<block type="procedures_callnoreturn" id="163"> | ||
<mutation name="Contar estrella si hay" /> | ||
<next> | ||
<block type="procedures_callnoreturn" id="157"> | ||
<mutation name="Contar planeta si hay" /> | ||
</block> | ||
</next> | ||
</block> | ||
</next> | ||
</block> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="49" x="13" y="211"> | ||
<mutation /> | ||
<field name="NAME">Contar estrella si hay</field> | ||
<statement name="STACK"> | ||
<block type="si" id="202" inline="true"> | ||
<value name="condition"> | ||
<block type="TocandoEstrellaManic" id="217" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="ContarEstrella" id="228" /> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="46" x="411" y="227"> | ||
<mutation /> | ||
<field name="NAME">Contar planeta si hay</field> | ||
<statement name="STACK"> | ||
<block type="si" id="240" inline="true"> | ||
<value name="condition"> | ||
<block type="TocandoPlaneta" id="222" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="ContarPlaneta" id="234" /> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
<block type="procedures_defnoreturn" id="58" x="154" y="312"> | ||
<mutation /> | ||
<field name="NAME">Volver al inicio</field> | ||
<statement name="STACK"> | ||
<block type="hasta" id="251" inline="true"> | ||
<value name="condition"> | ||
<block type="EstoySobreElInicioManic" id="256" /> | ||
</value> | ||
<statement name="block"> | ||
<block type="MoverACasillaArriba" id="262" /> | ||
</statement> | ||
</block> | ||
</statement> | ||
</block> | ||
</xml>`, | ||
}); | ||
|
||
|
||
}); |
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
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
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
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
Oops, something went wrong.