Update versions of depdencies.
[online-glom:gwt-glom.git] / src / test / java / org / glom / web / client / GwtTestOnlineGlom.java
1 package org.glom.web.client;
2
3 import static org.junit.Assert.*;
4
5 import org.glom.web.client.ui.DocumentSelectionView;
6 import org.junit.Before;
7 import org.junit.Test;
8
9 import com.googlecode.gwt.test.GwtModule;
10 import com.googlecode.gwt.test.GwtTestWithEasyMock;
11
12 @GwtModule("org.glom.web.OnlineGlom")
13 public class GwtTestOnlineGlom extends GwtTestWithEasyMock {
14
15         /**
16          * Tell gwt-test-utils to use this mock when trying to create this class via GWT.create() in OnlineGlom.
17          */
18         // @Mock
19         // private AppPlaceHistoryMapper mockAppPlaceHistoryMapper;
20
21         private OnlineGlom app;
22
23         @Test
24         public void testSomething() {
25                 assertTrue(true);
26                 /*
27                  * TODO: For instance: // Arrange Browser.fillText(app.nameField, "123");
28                  * 
29                  * // Act Browser.click(app.sendButton);
30                  * 
31                  * // Assert assertFalse(app.dialogBox.isShowing()); assertEquals("Please enter at least four characters",
32                  * app.errorLabel.getText());
33                  */
34         }
35
36         @Before
37         public void beforeOnlineGlom() {
38                 app = new OnlineGlom();
39                 app.onModuleLoad();
40
41                 assertNotNull(app.clientFactory);
42                 final DocumentSelectionView view = app.clientFactory.getDocumentSelectionView();
43                 assertNotNull(view);
44                 assertNotNull(view.asWidget());
45                 assertTrue(view.asWidget().isVisible());
46
47                 // Some pre-assertions
48                 assertTrue(app.docSelectionPanel.isVisible());
49                 assertFalse(app.dataPanel.isVisible());
50                 assertFalse(app.tableSelectionPanel.isVisible());
51                 // TODO: For instance: assertEquals("", app.docSelectionPanel.getText());
52         }
53
54 }