package test;

import static org.junit.Assert.*;
import model.BuilderModel;

import org.junit.Test;

import boundary.BuilderApplication;
import boundary.BuilderLevelEditorView;
import boundary.BuilderMainMenuView;
import boundary.ResourceLoader;


/**
 * BuilderLevelEditorView tests
 *
 * @author Cem Unsal, and Maurizio Vitale
 */

public class TestBuilderLevelEditor {

	BuilderApplication app;
	BuilderModel model;
	ResourceLoader loader;
	BuilderLevelEditorView levelEditorView;
	
	
	private void setUp() {
	    loader = new ResourceLoader();
	    model = new BuilderModel();
	    app = new BuilderApplication(model, loader);
	    levelEditorView = new BuilderLevelEditorView(app, model);
	}
	
	private void tearDown() {
		app.dispose();
		app = null;
	}
	
	@Test
	public void test() {
		setUp();
		app.setView(new BuilderMainMenuView(app, model));
		assertTrue(app.getView() instanceof BuilderMainMenuView);
		tearDown();	
	}

}

@@ -628,74 +628,11 @@
 r);%0A
-%09    levelEditorView = new BuilderLevelEditorView(app, model);%0A
 %09%7D%0A
+
 %09%0A%09p
@@ -728,24 +728,68 @@
 %0A%09%09setUp();%0A
+%09%09//Test that MainMenuView has been initial%0A
 %09%09app.setVie
@@ -828,16 +828,16 @@
 odel));%0A
-
 %09%09assert
@@ -888,16 +888,79 @@
 uView);%0A
+%09    levelEditorView = new BuilderLevelEditorView(app, model);%0A
 %09%09tearDo

Fix TestBuilderLevelEditor