Ejemplo n.º 1
0
		public void testBeerContainerType  ()
		{
			//SETUP
			Beer beer = new Beer ("Pilsner", 		Beer.CONTAINER_TYPE_BOTTLE);

			//ASSERTION
			Assert.AreEqual (Beer.CONTAINER_TYPE_BOTTLE, beer.containerType);
		}
Ejemplo n.º 2
0
		public void testDefaultCalories  ([Values (0, 100, 10000)] float a)
		{
			//SETUP
			Beer beer = new Beer ("Pilsner", 		Beer.CONTAINER_TYPE_BOTTLE);
			beer.calories = (uint)a;

			//ASSERTION
			Assert.AreEqual (a, beer.calories);
		}
Ejemplo n.º 3
0
		public void testNameSetFromSetter  ()
		{
			//SETUP
			Beer beer = new Beer ("Pilsner", 		Beer.CONTAINER_TYPE_BOTTLE);
			beer.name = "PilsnerNew";
			
			//ASSERTION
			Assert.AreEqual ("PilsnerNew", 			beer.name);
		}
Ejemplo n.º 4
0
		public void testNameSetFromConstructor  ()
		{
			//SETUP
			Beer beer = new Beer ("Pilsner", 		Beer.CONTAINER_TYPE_BOTTLE);
			
			//ASSERTION
			Assert.AreEqual ("Pilsner", 			beer.name);
		}
Ejemplo n.º 5
0
		// PUBLIC
		/// <summary>
		/// _dos the run demo.
		/// </summary>
		public void _doRunDemo() 
		{

			//HERE IN THE 'REGULAR' TREE OF OUR CODE WE WOULD BE MAKING OUR
			//	GAME AND 'USING' OUR CLASSES LIKE NORMAL, WHATEVER 
			//	TYPE THEY MIGHT BE

			//NOTHING SPECIAL HAPPENING HERE...
			Beer beer = new Beer ("Pilsner", Beer.CONTAINER_TYPE_BOTTLE);
			Debug.Log ("beer: " + beer.calories);

			//NOR HERE...
			Soda soda = new Soda ("GreenLightening");
			Debug.Log ("soda: " + soda.name);



		}