public BakedBeansSet() { RecipeLoader loader = new RecipeLoader(); Recipe = loader.LoadRecipe(0); CompatibleBuildings = new BuildingTypes[1]; CompatibleBuildings[0] = BuildingTypes.CanningFactory; }
// Use this for initialization void Start() { ingredObjList = new List <GameObject> (); instructObjList = new List <GameObject> (); instance = this; grid = gridObject.GetComponent <GridLayoutGroup> (); Recipes.instance.ParseFile(Recipes.instance.recipeFilePath); }
public void RecipeLoaderSetPermalinkLoading_ShouldSetWithPermalink() { var recipe = Mock.Recipes.SWEET_AND_SPICY_CHICKEN; var recipeLoader = new RecipeLoader(this.Context, recipe); var loader = recipeLoader.SetPermalinkLoading(); Assert.AreEqual(true, recipeLoader.WithPermalink); }
public void RecipeLoaderSetCookbookStatusLoading_ShouldSetWithCookbookStatus() { var recipe = Mock.Recipes.SWEET_AND_SPICY_CHICKEN; var recipeLoader = new RecipeLoader(this.Context, recipe); var loader = recipeLoader.SetCookbookStatusLoading(); Assert.AreEqual(true, recipeLoader.WithCookbookStatus); }
public void RecipeLoaderLoad_ShouldAddARecipeToTheCollection() { var recipe = Mock.Recipes.SWEET_AND_SPICY_CHICKEN; var recipe2 = Mock.Recipes.QUICK_SANDWHICH; var recipeLoader = new RecipeLoader(this.Context, recipe); var loader = recipeLoader.Load(recipe2); CollectionAssert.AreEqual(new List <Recipe>() { recipe, recipe2 }, recipeLoader.RecipesToLoad); }
public void RecipeLoaderList_ShouldCallContextReadRecipe() { var recipe = Mock.Recipes.SWEET_AND_SPICY_CHICKEN; var recipeLoader = new RecipeLoader(this.Context, recipe); recipeLoader.SetMethodLoading(); recipeLoader.SetPermalinkLoading(); this.Context.RRCalledTimes = 0; var loader = recipeLoader.List(); Assert.AreEqual(1, this.Context.RRCalledTimes); Assert.AreEqual(recipeLoader.WithCommentCount, this.Context.options.ReturnCommentCount); Assert.AreEqual(recipeLoader.WithCookbookStatus, this.Context.options.ReturnCookbookStatus); Assert.AreEqual(recipeLoader.WithUserRating, this.Context.options.ReturnUserRating); Assert.AreEqual(recipeLoader.WithPermalink, this.Context.options.ReturnPermalink); Assert.AreEqual(recipeLoader.WithMethod, this.Context.options.ReturnMethod); }
protected Configuration GetConfiguration() { Configuration nhConfig = null; if (RecipeLoader.DefaultConfiguration != null) { nhConfig = RecipeLoader.DefaultConfiguration(); } nhConfig = nhConfig ?? new Configuration().DataBaseIntegration(db => { db.Dialect <SQLiteDialect>(); db.Driver <SQLite20Driver>(); db.ConnectionProvider <SharedConnectionConnectionProvider>(); db.ConnectionString = "FullUri=file:memorydb.db"; }); nhConfig.DataBaseIntegration(db => { db.LogFormattedSql = true; db.LogSqlInConsole = false; }); nhConfig.SetProperty("generate_statistics", "true"); return(nhConfig); }
public void RecipeLoaderSetUserRatingLoading_ShouldSetWithUserRating() { var recipe = Mock.Recipes.SWEET_AND_SPICY_CHICKEN; var recipeLoader = new RecipeLoader(this.Context, recipe); var loader = recipeLoader.SetUserRatingLoading(); Assert.AreEqual(true, recipeLoader.WithUserRating); }
public void RecipeLoaderLoad_ShouldAddARecipeToTheCollection() { var recipe = Mock.Recipes.SWEET_AND_SPICY_CHICKEN; var recipe2 = Mock.Recipes.QUICK_SANDWHICH; var recipeLoader = new RecipeLoader(this.Context, recipe); var loader = recipeLoader.Load(recipe2); CollectionAssert.AreEqual(new List<Recipe>() { recipe, recipe2 }, recipeLoader.RecipesToLoad); }
public void Awake() { instance = this; InitializeDatabase(); Debug.Log(itemDatabase.Count); }
protected sealed override void Register() { ModTypeLookup <GlobalRecipe> .Register(this); RecipeLoader.Add(this); }