Package com.eclipsesource.restfuse.internal

Source Code of com.eclipsesource.restfuse.internal.BasicStatement

/*******************************************************************************
* Copyright (c) 2011 EclipseSource and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
*    Holger Staudacher - initial API and implementation
******************************************************************************/
package com.eclipsesource.restfuse.internal;

import org.junit.runners.model.Statement;

import com.eclipsesource.restfuse.Response;


public class BasicStatement extends Statement {
 
  private final Statement statement;
  private final HttpTestStatement base;

  public BasicStatement( Statement statement, HttpTestStatement base ) {
    this.base = base;
    this.statement = statement;
  }

  @Override
  public void evaluate() throws Throwable {
    Response response = base.sendRequest();
    base.tryInjectResponse( response );
    statement.evaluate();
  }
}
TOP

Related Classes of com.eclipsesource.restfuse.internal.BasicStatement

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.