[LIB-9] Separate chesshog-format module
[chesshog.git] / chesshog-format / src / test / resources / org / hedgecode / chess / fen / FENBuilderTest.xml
diff --git a/chesshog-format/src/test/resources/org/hedgecode/chess/fen/FENBuilderTest.xml b/chesshog-format/src/test/resources/org/hedgecode/chess/fen/FENBuilderTest.xml
new file mode 100644 (file)
index 0000000..a68df57
--- /dev/null
@@ -0,0 +1,114 @@
+<?xml version='1.0' encoding='UTF-8'?>
+
+<!--
+  ~ Copyright (c) 2018. Developed by Hedgecode.
+  ~
+  ~ Licensed under the Apache License, Version 2.0 (the "License");
+  ~ you may not use this file except in compliance with the License.
+  ~ You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing, software
+  ~ distributed under the License is distributed on an "AS IS" BASIS,
+  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  ~ See the License for the specific language governing permissions and
+  ~ limitations under the License.
+  -->
+
+<config>
+    <tests>
+        <test>
+            <name>Initial Position</name>
+            <fen>rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1</fen>
+            <position>
+                <initial>true</initial>
+            </position>
+        </test>
+        <test>
+            <name>Morphy's Opera Game</name>
+            <fen>4kb1r/p2n1ppp/4q3/4p1B1/4P3/1Q6/PPP2PPP/2KR4 w k - 0 16</fen>
+            <position>
+                <squares>
+                    <c1>WHITE_KING</c1>
+                    <b3>WHITE_QUEEN</b3>
+                    <d1>WHITE_ROOK</d1>
+                    <g5>WHITE_BISHOP</g5>
+                    <a2>WHITE_PAWN</a2>
+                    <b2>WHITE_PAWN</b2>
+                    <c2>WHITE_PAWN</c2>
+                    <e4>WHITE_PAWN</e4>
+                    <f2>WHITE_PAWN</f2>
+                    <g2>WHITE_PAWN</g2>
+                    <h2>WHITE_PAWN</h2>
+                    <e8>BLACK_KING</e8>
+                    <e6>BLACK_QUEEN</e6>
+                    <h8>BLACK_ROOK</h8>
+                    <f8>BLACK_BISHOP</f8>
+                    <d7>BLACK_KNIGHT</d7>
+                    <a7>BLACK_PAWN</a7>
+                    <e5>BLACK_PAWN</e5>
+                    <f7>BLACK_PAWN</f7>
+                    <g7>BLACK_PAWN</g7>
+                    <h7>BLACK_PAWN</h7>
+                </squares>
+                <move>WHITE</move>
+                <castle>
+                    <white>NONE</white>
+                    <black>KING</black>
+                </castle>
+                <halfmove>0</halfmove>
+                <fullmove>16</fullmove>
+            </position>
+        </test>
+        <test>
+            <name>Immortal Game</name>
+            <fen>r1bk2nr/p2p1pNp/n2B4/1p1NP2P/6P1/3P1Q2/P1P1K3/q5b1 w - - 1 22</fen>
+            <position>
+                <squares>
+                    <e2>WHITE_KING</e2>
+                    <f3>WHITE_QUEEN</f3>
+                    <d6>WHITE_BISHOP</d6>
+                    <d5>WHITE_KNIGHT</d5>
+                    <g7>WHITE_KNIGHT</g7>
+                    <a2>WHITE_PAWN</a2>
+                    <c2>WHITE_PAWN</c2>
+                    <d3>WHITE_PAWN</d3>
+                    <e5>WHITE_PAWN</e5>
+                    <g4>WHITE_PAWN</g4>
+                    <h5>WHITE_PAWN</h5>
+                    <d8>BLACK_KING</d8>
+                    <a1>BLACK_QUEEN</a1>
+                    <a8>BLACK_ROOK</a8>
+                    <h8>BLACK_ROOK</h8>
+                    <c8>BLACK_BISHOP</c8>
+                    <g1>BLACK_BISHOP</g1>
+                    <a6>BLACK_KNIGHT</a6>
+                    <g8>BLACK_KNIGHT</g8>
+                    <a7>BLACK_PAWN</a7>
+                    <b5>BLACK_PAWN</b5>
+                    <d7>BLACK_PAWN</d7>
+                    <f7>BLACK_PAWN</f7>
+                    <h7>BLACK_PAWN</h7>
+                </squares>
+                <move>WHITE</move>
+                <castle>
+                    <white>NONE</white>
+                    <black>NONE</black>
+                </castle>
+                <halfmove>1</halfmove>
+                <fullmove>22</fullmove>
+            </position>
+        </test>
+        <test>
+            <name>Empty Position</name>
+            <fen>8/8/8/8/8/8/8/8 w - - 0 1</fen>
+            <position>
+                <empty>true</empty>
+                <move>WHITE</move>
+                <halfmove>0</halfmove>
+                <fullmove>1</fullmove>
+            </position>
+        </test>
+    </tests>
+</config>