private void Start() { plateau = GameObject.FindGameObjectsWithTag("Plateau")[0]; plateauController = plateau.GetComponent <PlateauController>(); //panel = GameObject.Find("buttonPanel"); //panel.SetActive(true); }
public void GetAllPlateausTest() { List <Plateau> testPlateaus = DataContext.Plateaus; PlateauController controller = new PlateauController(); List <Plateau> result = controller.Get() as List <Plateau>; Assert.AreEqual(testPlateaus.Count, result.Count); }
// Start is called before the first frame update void Start() { playerT = GetComponentInParent <Transform>(); currentCel = 1; compteurTour = 0; compteur = 0; movingTime = 0; plateau = GameObject.FindGameObjectsWithTag("Plateau")[0]; plateauController = plateau.GetComponent <PlateauController>(); }
public void PlateauController_ShouldReturnCorrectPlateau() { Guid id = new Guid("653648ee-6a4b-4a12-ab74-b5f9663b06cd"); Plateau testPlateau = DataContext.Plateaus.Where(p => p.Id == id).FirstOrDefault(); PlateauController controller = new PlateauController(); Plateau result = controller.Get(id); Assert.IsNotNull(result); Assert.AreEqual(testPlateau.Name, result.Name); }