Permalink
Browse files

Added fail tests for the file parsers.

  • Loading branch information...
tzlaine committed Oct 30, 2011
1 parent ec95b6a commit 5e3e0ec7e289401a20397b09253ec85b2d19871e
Showing with 40,285 additions and 1 deletion.
  1. +11 −0 test/CMakeLists.txt
  2. +4,419 −0 test/buildings_errors
  3. +12 −0 test/fleet_plans_errors
  4. +18 −0 test/items_errors
  5. +147 −0 test/monster_fleet_plans_errors
  6. +36 −0 test/ship_designs_errors
  7. +1,791 −0 test/ship_hulls_errors
  8. +1,297 −0 test/ship_parts_errors
  9. +291 −0 test/specials_errors
  10. +1,827 −0 test/species_errors
  11. +30,370 −0 test/techs_errors
  12. +66 −1 test/test.cpp
View
@@ -281,3 +281,14 @@ add_test_and_data_files(parser_test condition_parser -f condition_parser_1_error
add_test_and_data_files(parser_test condition_parser -f condition_parser_2_errors --fail)
add_test_and_data_files(parser_test condition_parser -f condition_parser_3_errors --fail)
add_test_and_data_files(parser_test effect_parser -f effect_parser_errors --fail)
+
+add_test_and_data_files(parser_test buildings_parser -f buildings_errors --fail)
+add_test_and_data_files(parser_test specials_parser -f specials_errors --fail)
+add_test_and_data_files(parser_test species_parser -f species_errors --fail)
+add_test_and_data_files(parser_test techs_parser -f techs_errors --fail)
+add_test_and_data_files(parser_test items_parser -f items_errors --fail)
+add_test_and_data_files(parser_test ship_parts_parser -f ship_parts_errors --fail)
+add_test_and_data_files(parser_test ship_hulls_parser -f ship_hulls_errors --fail)
+add_test_and_data_files(parser_test ship_designs_parser -f ship_designs_errors --fail)
+add_test_and_data_files(parser_test fleet_plans_parser -f fleet_plans_errors --fail)
+add_test_and_data_files(parser_test monster_fleet_plans_parser -f monster_fleet_plans_errors --fail)
View

Large diffs are not rendered by default.

Oops, something went wrong.
View
@@ -0,0 +1,12 @@
+Fleet
+Fleet Name
+Fleet Name =
+Fleet Name = "Foo 0"
+Fleet Name = "Foo 0" Ships
+Fleet Name = "Foo 0" Ships =
+Fleet Name = "Foo 1"
+Fleet Name = "Foo 1" Ships
+Fleet Name = "Foo 1" Ships =
+Fleet Name = "Foo 1" Ships = [
+Fleet Name = "Foo 1" Ships = [ "Foo"
+Fleet Name = "Foo 1" Ships = [ "Foo" "Foo"
View
@@ -0,0 +1,18 @@
+Item
+Item Type
+Item Type =
+Item Type = Building
+Item Type = Building Name
+Item Type = Building Name =
+Item Type = ShipPart
+Item Type = ShipPart Name
+Item Type = ShipPart Name =
+Item Type = ShipHull
+Item Type = ShipHull Name
+Item Type = ShipHull Name =
+Item Type = ShipDesign
+Item Type = ShipDesign Name
+Item Type = ShipDesign Name =
+Item Type = Tech
+Item Type = Tech Name
+Item Type = Tech Name =
@@ -0,0 +1,147 @@
+MonsterFleet
+MonsterFleet Name
+MonsterFleet Name =
+MonsterFleet Name = "Foo 1"
+MonsterFleet Name = "Foo 1" Ships
+MonsterFleet Name = "Foo 1" Ships =
+MonsterFleet Name = "Foo 1" Ships = "Foo"
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate =
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate = 1.0
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate = 1.0 SpawnLimit
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate = 1.0 SpawnLimit =
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate = 1.0 SpawnLimit = 1
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate = 1.0 SpawnLimit = 1 Location
+MonsterFleet Name = "Foo 1" Ships = "Foo" SpawnRate = 1.0 SpawnLimit = 1 Location =
+MonsterFleet Name = "Foo 2"
+MonsterFleet Name = "Foo 2" Ships
+MonsterFleet Name = "Foo 2" Ships =
+MonsterFleet Name = "Foo 2" Ships = "Foo"
+MonsterFleet Name = "Foo 2" Ships = "Foo" SpawnRate
+MonsterFleet Name = "Foo 2" Ships = "Foo" SpawnRate =
+MonsterFleet Name = "Foo 2" Ships = "Foo" SpawnRate = 1.0
+MonsterFleet Name = "Foo 2" Ships = "Foo" SpawnRate = 1.0 SpawnLimit
+MonsterFleet Name = "Foo 2" Ships = "Foo" SpawnRate = 1.0 SpawnLimit =
+MonsterFleet Name = "Foo 3"
+MonsterFleet Name = "Foo 3" Ships
+MonsterFleet Name = "Foo 3" Ships =
+MonsterFleet Name = "Foo 3" Ships = "Foo"
+MonsterFleet Name = "Foo 3" Ships = "Foo" SpawnRate
+MonsterFleet Name = "Foo 3" Ships = "Foo" SpawnRate =
+MonsterFleet Name = "Foo 3" Ships = "Foo" SpawnRate = 1.0
+MonsterFleet Name = "Foo 3" Ships = "Foo" SpawnRate = 1.0 Location
+MonsterFleet Name = "Foo 3" Ships = "Foo" SpawnRate = 1.0 Location =
+MonsterFleet Name = "Foo 4"
+MonsterFleet Name = "Foo 4" Ships
+MonsterFleet Name = "Foo 4" Ships =
+MonsterFleet Name = "Foo 4" Ships = "Foo"
+MonsterFleet Name = "Foo 4" Ships = "Foo" SpawnRate
+MonsterFleet Name = "Foo 4" Ships = "Foo" SpawnRate =
+MonsterFleet Name = "Foo 5"
+MonsterFleet Name = "Foo 5" Ships
+MonsterFleet Name = "Foo 5" Ships =
+MonsterFleet Name = "Foo 5" Ships = "Foo"
+MonsterFleet Name = "Foo 5" Ships = "Foo" SpawnLimit
+MonsterFleet Name = "Foo 5" Ships = "Foo" SpawnLimit =
+MonsterFleet Name = "Foo 5" Ships = "Foo" SpawnLimit = 1
+MonsterFleet Name = "Foo 5" Ships = "Foo" SpawnLimit = 1 Location
+MonsterFleet Name = "Foo 5" Ships = "Foo" SpawnLimit = 1 Location =
+MonsterFleet Name = "Foo 6"
+MonsterFleet Name = "Foo 6" Ships
+MonsterFleet Name = "Foo 6" Ships =
+MonsterFleet Name = "Foo 6" Ships = "Foo"
+MonsterFleet Name = "Foo 6" Ships = "Foo" SpawnLimit
+MonsterFleet Name = "Foo 6" Ships = "Foo" SpawnLimit =
+MonsterFleet Name = "Foo 7"
+MonsterFleet Name = "Foo 7" Ships
+MonsterFleet Name = "Foo 7" Ships =
+MonsterFleet Name = "Foo 7" Ships = "Foo"
+MonsterFleet Name = "Foo 7" Ships = "Foo" Location
+MonsterFleet Name = "Foo 7" Ships = "Foo" Location =
+MonsterFleet Name = "Foo 8"
+MonsterFleet Name = "Foo 8" Ships
+MonsterFleet Name = "Foo 8" Ships =
+MonsterFleet Name = "Foo 9"
+MonsterFleet Name = "Foo 9" Ships
+MonsterFleet Name = "Foo 9" Ships =
+MonsterFleet Name = "Foo 9" Ships = [
+MonsterFleet Name = "Foo 9" Ships = [ "Foo"
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo"
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ]
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate =
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 SpawnLimit
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 SpawnLimit =
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 SpawnLimit = 1
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 SpawnLimit = 1 Location
+MonsterFleet Name = "Foo 9" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 SpawnLimit = 1 Location =
+MonsterFleet Name = "Foo 10"
+MonsterFleet Name = "Foo 10" Ships
+MonsterFleet Name = "Foo 10" Ships =
+MonsterFleet Name = "Foo 10" Ships = [
+MonsterFleet Name = "Foo 10" Ships = [ "Foo"
+MonsterFleet Name = "Foo 10" Ships = [ "Foo" "Foo"
+MonsterFleet Name = "Foo 10" Ships = [ "Foo" "Foo" ]
+MonsterFleet Name = "Foo 10" Ships = [ "Foo" "Foo" ] SpawnRate
+MonsterFleet Name = "Foo 10" Ships = [ "Foo" "Foo" ] SpawnRate =
+MonsterFleet Name = "Foo 10" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0
+MonsterFleet Name = "Foo 10" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 SpawnLimit
+MonsterFleet Name = "Foo 10" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 SpawnLimit =
+MonsterFleet Name = "Foo 11"
+MonsterFleet Name = "Foo 11" Ships
+MonsterFleet Name = "Foo 11" Ships =
+MonsterFleet Name = "Foo 11" Ships = [
+MonsterFleet Name = "Foo 11" Ships = [ "Foo"
+MonsterFleet Name = "Foo 11" Ships = [ "Foo" "Foo"
+MonsterFleet Name = "Foo 11" Ships = [ "Foo" "Foo" ]
+MonsterFleet Name = "Foo 11" Ships = [ "Foo" "Foo" ] SpawnRate
+MonsterFleet Name = "Foo 11" Ships = [ "Foo" "Foo" ] SpawnRate =
+MonsterFleet Name = "Foo 11" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0
+MonsterFleet Name = "Foo 11" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 Location
+MonsterFleet Name = "Foo 11" Ships = [ "Foo" "Foo" ] SpawnRate = 1.0 Location =
+MonsterFleet Name = "Foo 12"
+MonsterFleet Name = "Foo 12" Ships
+MonsterFleet Name = "Foo 12" Ships =
+MonsterFleet Name = "Foo 12" Ships = [
+MonsterFleet Name = "Foo 12" Ships = [ "Foo"
+MonsterFleet Name = "Foo 12" Ships = [ "Foo" "Foo"
+MonsterFleet Name = "Foo 12" Ships = [ "Foo" "Foo" ]
+MonsterFleet Name = "Foo 12" Ships = [ "Foo" "Foo" ] SpawnRate
+MonsterFleet Name = "Foo 12" Ships = [ "Foo" "Foo" ] SpawnRate =
+MonsterFleet Name = "Foo 13"
+MonsterFleet Name = "Foo 13" Ships
+MonsterFleet Name = "Foo 13" Ships =
+MonsterFleet Name = "Foo 13" Ships = [
+MonsterFleet Name = "Foo 13" Ships = [ "Foo"
+MonsterFleet Name = "Foo 13" Ships = [ "Foo" "Foo"
+MonsterFleet Name = "Foo 13" Ships = [ "Foo" "Foo" ]
+MonsterFleet Name = "Foo 13" Ships = [ "Foo" "Foo" ] SpawnLimit
+MonsterFleet Name = "Foo 13" Ships = [ "Foo" "Foo" ] SpawnLimit =
+MonsterFleet Name = "Foo 13" Ships = [ "Foo" "Foo" ] SpawnLimit = 1
+MonsterFleet Name = "Foo 13" Ships = [ "Foo" "Foo" ] SpawnLimit = 1 Location
+MonsterFleet Name = "Foo 13" Ships = [ "Foo" "Foo" ] SpawnLimit = 1 Location =
+MonsterFleet Name = "Foo 14"
+MonsterFleet Name = "Foo 14" Ships
+MonsterFleet Name = "Foo 14" Ships =
+MonsterFleet Name = "Foo 14" Ships = [
+MonsterFleet Name = "Foo 14" Ships = [ "Foo"
+MonsterFleet Name = "Foo 14" Ships = [ "Foo" "Foo"
+MonsterFleet Name = "Foo 14" Ships = [ "Foo" "Foo" ]
+MonsterFleet Name = "Foo 14" Ships = [ "Foo" "Foo" ] SpawnLimit
+MonsterFleet Name = "Foo 14" Ships = [ "Foo" "Foo" ] SpawnLimit =
+MonsterFleet Name = "Foo 15"
+MonsterFleet Name = "Foo 15" Ships
+MonsterFleet Name = "Foo 15" Ships =
+MonsterFleet Name = "Foo 15" Ships = [
+MonsterFleet Name = "Foo 15" Ships = [ "Foo"
+MonsterFleet Name = "Foo 15" Ships = [ "Foo" "Foo"
+MonsterFleet Name = "Foo 15" Ships = [ "Foo" "Foo" ]
+MonsterFleet Name = "Foo 15" Ships = [ "Foo" "Foo" ] Location
+MonsterFleet Name = "Foo 15" Ships = [ "Foo" "Foo" ] Location =
+MonsterFleet Name = "Foo 16"
+MonsterFleet Name = "Foo 16" Ships
+MonsterFleet Name = "Foo 16" Ships =
+MonsterFleet Name = "Foo 16" Ships = [
+MonsterFleet Name = "Foo 16" Ships = [ "Foo"
+MonsterFleet Name = "Foo 16" Ships = [ "Foo" "Foo"
View
@@ -0,0 +1,36 @@
+ShipDesign
+ShipDesign Name
+ShipDesign Name =
+ShipDesign Name = "Foo 0"
+ShipDesign Name = "Foo 0" Description
+ShipDesign Name = "Foo 0" Description =
+ShipDesign Name = "Foo 0" Description = "Bar"
+ShipDesign Name = "Foo 0" Description = "Bar" Hull
+ShipDesign Name = "Foo 0" Description = "Bar" Hull =
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo"
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts =
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts = "Foo"
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts = "Foo" Graphic
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts = "Foo" Graphic =
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts = "Foo" Graphic = "Baz"
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts = "Foo" Graphic = "Baz" Model
+ShipDesign Name = "Foo 0" Description = "Bar" Hull = "Foo" Parts = "Foo" Graphic = "Baz" Model =
+ShipDesign Name = "Foo 1"
+ShipDesign Name = "Foo 1" Description
+ShipDesign Name = "Foo 1" Description =
+ShipDesign Name = "Foo 1" Description = "Bar"
+ShipDesign Name = "Foo 1" Description = "Bar" Hull
+ShipDesign Name = "Foo 1" Description = "Bar" Hull =
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo"
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts =
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo"
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo" "Foo"
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo" "Foo" ]
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo" "Foo" ] Graphic
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo" "Foo" ] Graphic =
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo" "Foo" ] Graphic = "Baz"
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo" "Foo" ] Graphic = "Baz" Model
+ShipDesign Name = "Foo 1" Description = "Bar" Hull = "Foo" Parts = [ "Foo" "Foo" ] Graphic = "Baz" Model =
Oops, something went wrong.

0 comments on commit 5e3e0ec

Please sign in to comment.