当前位置: 首页>>代码示例>>Java>>正文


Java Assertable类代码示例

本文整理汇总了Java中com.eviware.soapui.model.testsuite.Assertable的典型用法代码示例。如果您正苦于以下问题:Java Assertable类的具体用法?Java Assertable怎么用?Java Assertable使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


Assertable类属于com.eviware.soapui.model.testsuite包,在下文中一共展示了Assertable类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: prepareTestScriptContext

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
public static ScriptContext prepareTestScriptContext(WsdlProject project, Assertable assertable) {
    ScriptContext context = preparePreRequestScriptContext(project);

    AddHttpCodeAssertionCommand addHttpCodeAssertionCommand = new AddHttpCodeAssertionCommand(assertable);
    PostmanObject responseCodeObject = new PostmanObject();
    responseCodeObject.addCommand(addHttpCodeAssertionCommand);
    context.addObject(RESPONSE_CODE, responseCodeObject);

    context.addObject(RESPONSE_TIME, new PostmanObject(new AddSlaAssertionCommand(assertable)));

    PostmanObject responseBodyObject = new PostmanObject(new AddEqualsAssertionCommand(assertable));
    responseBodyObject.addCommand(new AddSimpleContainsAssertionCommand(assertable));
    context.addObject(RESPONSE_BODY, responseBodyObject);

    PostmanObject globalsObject = new PostmanObject();
    globalsObject.addCommand(new GetGlobalVariableCommand());
    context.addObject(GLOBALS, globalsObject);

    PostmanObject postmanObject = context.getObject(POSTMAN_OBJECT);
    postmanObject.addCommand(new AddHeaderExistsAssertionCommand(assertable));

    return context;
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:24,代码来源:ScriptContext.java

示例2: updateStatusIcon

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
private void updateStatusIcon() {
    Assertable.AssertionStatus status = getModelItem().getAssertionStatus();
    switch (status) {
        case FAILED: {
            assertionInspector.setIcon(UISupport.createImageIcon("com/smartbear/mqttsupport/failed_assertion.png"));
            inspectorPanel.activate(assertionInspector);
            break;
        }
        case UNKNOWN: {
            assertionInspector.setIcon(UISupport.createImageIcon("com/smartbear/mqttsupport/unknown_assertion.png"));
            break;
        }
        case VALID: {
            assertionInspector.setIcon(UISupport.createImageIcon("com/smartbear/mqttsupport/valid_assertion.png"));
            inspectorPanel.deactivate();
            break;
        }
    }
}
 
开发者ID:SmartBear,项目名称:ready-mqtt-plugin,代码行数:20,代码来源:ReceiveTestStepPanel.java

示例3: updateStatusIcon

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
private void updateStatusIcon() {
    Assertable.AssertionStatus status = getModelItem().getAssertionStatus();
    switch (status) {
    case FAILED: {
        assertionInspector.setIcon(UISupport.createImageIcon("/failed_assertion.gif"));
        inspectorPanel.activate(assertionInspector);
        break;
    }
    case UNKNOWN: {
        assertionInspector.setIcon(UISupport.createImageIcon("/unknown_assertion.png"));
        break;
    }
    case VALID: {
        assertionInspector.setIcon(UISupport.createImageIcon("/valid_assertion.gif"));
        inspectorPanel.deactivate();
        break;
    }
    }
}
 
开发者ID:hschott,项目名称:ready-websocket-plugin,代码行数:20,代码来源:ReceiveTestStepPanel.java

示例4: addAssertions

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
void addAssertions(String tests, WsdlProject project, Assertable assertable) {
    PostmanScriptTokenizer tokenizer = new PostmanScriptTokenizer();
    PostmanScriptParser parser = new PostmanScriptParser();
    try {
        LinkedList<Token> tokens = tokenizer.tokenize(tests);

        ScriptContext context = ScriptContext.prepareTestScriptContext(project, assertable);
        parser.parse(tokens, context);
    } catch (SoapUIException e) {
        e.printStackTrace();
    }
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:13,代码来源:PostmanImporter.java

示例5: AddEqualsAssertionCommand

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
public AddEqualsAssertionCommand(Assertable assertable) {
    this.assertable = assertable;
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:4,代码来源:AddEqualsAssertionCommand.java

示例6: AddSimpleContainsAssertionCommand

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
public AddSimpleContainsAssertionCommand(Assertable assertable) {
    this.assertable = assertable;
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:4,代码来源:AddSimpleContainsAssertionCommand.java

示例7: AddScriptAssertionCommand

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
public AddScriptAssertionCommand(Assertable assertable) {
    this.assertable = assertable;
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:4,代码来源:AddScriptAssertionCommand.java

示例8: AddHeaderExistsAssertionCommand

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
public AddHeaderExistsAssertionCommand(Assertable assertable) {
    super(assertable);
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:4,代码来源:AddHeaderExistsAssertionCommand.java

示例9: AddHttpCodeAssertionCommand

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
public AddHttpCodeAssertionCommand(Assertable assertable) {
    this.assertable = assertable;
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:4,代码来源:AddHttpCodeAssertionCommand.java

示例10: AddSlaAssertionCommand

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
public AddSlaAssertionCommand(Assertable assertable) {
    this.assertable = assertable;
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:4,代码来源:AddSlaAssertionCommand.java

示例11: prepare

import com.eviware.soapui.model.testsuite.Assertable; //导入依赖的package包/类
@Before
public void prepare() {
    project = new WsdlProject();
    assertable = mock(Assertable.class);
}
 
开发者ID:SmartBear,项目名称:readyapi-postman-plugin,代码行数:6,代码来源:PostmanScriptParserTest.java


注:本文中的com.eviware.soapui.model.testsuite.Assertable类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。