Examples of JavaScriptPreviewPage


Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

    @Test
    public void testDeleteForum() {
      addSnippetParam("ForumService.forumUuid", forum.getForumUuid());
       
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertNull("Unexpected error detected on page", json.getString("code"));
        Assert.assertEquals(forum.getForumUuid(), json.getString("forumUuid"));
       
        forum = null; //getForum(forum.getForumUuid(), false);
        Assert.assertNull("Deleted forum is still available", forum);
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

        setAuthType(AuthType.AUTO_DETECT);
    }

    @Test
    public void testCreatePost() {
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertNotNull(json.getString("uid"));
    }
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

   
    @Test
    public void testDeleteForumError() {
      addSnippetParam("ForumService.forumUuid", "Foo");
       
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertEquals(404, json.getInt("code"));
        Assert.assertEquals("CLFRV0008E: Error, unable to find object with uuid: Foo", json.getString("message"));
    }
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

    @Test
    public void testDeleteForumInvalidArg() {
        setAuthType(AuthType.NONE);
      addSnippetParam("ForumService.forumUuid", "");
       
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertEquals(400, json.getInt("code"));
        Assert.assertEquals("Invalid argument, expected forumUuid.", json.getString("message"));
    }
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

        setAuthType(AuthType.AUTO_DETECT);
    }
   
    @Test
    public void testGetBlogComments() {
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        List jsonList = previewPage.getJsonList();
        Assert.assertFalse("GetBlogComments returned no results", jsonList.isEmpty());
    }
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

        setAuthType(AuthType.AUTO_DETECT);
    }

    @Test
    public void testGetComment() {
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertNotNull(json.getString("uid"));
    }
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

        setAuthType(AuthType.AUTO_DETECT);
    }
   
    @Test
    public void testGetMyBlogs() {
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        List jsonList = previewPage.getJsonList();
        Assert.assertFalse("GetMyBlogs returned no results", jsonList.isEmpty());
    }
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

    public void testDeleteForumTopic() {
      String title = createForumTopicName();
      ForumTopic forumTopic = createForumTopic(forum, title, title);
        addSnippetParam("ForumService.topicUuid", forumTopic.getTopicUuid());
       
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertNull("Unexpected error detected on page", json.getString("code"));
        Assert.assertEquals(forumTopic.getTopicUuid(), json.getString("topicUuid"));
       
        forumTopic = getForumTopic(forumTopic.getTopicUuid(), false);
        Assert.assertNull("Deleted forum topic is still available", forumTopic);
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

        setAuthType(AuthType.AUTO_DETECT);
    }
   
    @Test
    public void testDeletePost() {
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertNotNull(json.getString("deletedPostId"));
    }
View Full Code Here

Examples of com.ibm.sbt.automation.core.test.pageobjects.JavaScriptPreviewPage

   
    @Test
    public void testDeleteForumTopicError() {
      addSnippetParam("ForumService.topicUuid", "Foo");
       
        JavaScriptPreviewPage previewPage = executeSnippet(SNIPPET_ID);
        JsonJavaObject json = previewPage.getJson();
        Assert.assertEquals(404, json.getInt("code"));
        Assert.assertEquals("CLFRV0008E: Error, unable to find object with uuid: Foo", json.getString("message"));
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.