Merge pull request #14828 from silicons/sigh_516
fixes the crafting menu, adds an unit test to automatically yell at people who PR untested code that ended up breaking it for me (thanks drpanis)
This commit is contained in:
@@ -213,7 +213,7 @@
|
||||
)
|
||||
result = /obj/item/reagent_containers/food/snacks/salad/gumbo
|
||||
subcategory = CAT_MEAT
|
||||
|
||||
|
||||
/datum/crafting_recipe/food/goliathcalamari
|
||||
name = "Goliath Calamari"
|
||||
reqs = list(
|
||||
@@ -221,4 +221,4 @@
|
||||
/datum/reagent/consumable/cooking_oil = 10
|
||||
)
|
||||
result = /obj/item/reagent_containers/food/snacks/goliathcalamari
|
||||
|
||||
subcategory = CAT_MEAT
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
/datum/unit_test/crafting_recipes/Run()
|
||||
for(var/i in GLOB.crafting_recipes)
|
||||
var/datum/crafting_recipe/R = i
|
||||
if(!R.subcategory)
|
||||
Fail("Invalid subcategory on [R] ([R.type]).")
|
||||
if(!R.category && (R.cateogry != CAT_NONE))
|
||||
Fail("Invalid category on [R] ([R.type])")
|
||||
Reference in New Issue
Block a user