Search in sources :

Example 6 with TakeOffer

use of io.bisq.api.model.TakeOffer in project bisq-api by mrosseel.

the class OfferResourceIT method takeOffer_paymentAccountIdMissing_returns422status.

@InSequence(7)
@Test
public void takeOffer_paymentAccountIdMissing_returns422status() throws Exception {
    final TakeOffer payload = new TakeOffer(null, "1");
    takeOffer_template(createdOffer.id, payload, 422);
}
Also used : TakeOffer(io.bisq.api.model.TakeOffer) InSequence(org.jboss.arquillian.junit.InSequence) Test(org.junit.Test)

Example 7 with TakeOffer

use of io.bisq.api.model.TakeOffer in project bisq-api by mrosseel.

the class OfferResourceIT method takeOffer_noArbitratorSelected_returns424.

@Ignore("Bug in tradeManager.onTakeOffer which resolves instead of reject in this scenario")
@InSequence(7)
@Test
public void takeOffer_noArbitratorSelected_returns424() throws Exception {
    ApiTestHelper.deselectAllArbitrators(getBobPort());
    final TakeOffer payload = new TakeOffer(bobPaymentAccount.id, "1");
    takeOffer_template(createdOffer.id, payload, 423);
}
Also used : TakeOffer(io.bisq.api.model.TakeOffer) Ignore(org.junit.Ignore) InSequence(org.jboss.arquillian.junit.InSequence) Test(org.junit.Test)

Example 8 with TakeOffer

use of io.bisq.api.model.TakeOffer in project bisq-api by mrosseel.

the class OfferResourceIT method takeOffer_offerNotFound_returns404status.

@InSequence(7)
@Test
public void takeOffer_offerNotFound_returns404status() throws Exception {
    final TakeOffer payload = new TakeOffer(bobPaymentAccount.id, "1");
    takeOffer_template("non-existing-id", payload, 404);
}
Also used : TakeOffer(io.bisq.api.model.TakeOffer) InSequence(org.jboss.arquillian.junit.InSequence) Test(org.junit.Test)

Example 9 with TakeOffer

use of io.bisq.api.model.TakeOffer in project bisq-api by mrosseel.

the class OfferResourceIT method takeOffer_paymentAccountNotFound_returns425.

@InSequence(7)
@Test
public void takeOffer_paymentAccountNotFound_returns425() throws Exception {
    final TakeOffer payload = new TakeOffer("non-existing-account", "1");
    takeOffer_template(createdOffer.id, payload, 425);
}
Also used : TakeOffer(io.bisq.api.model.TakeOffer) InSequence(org.jboss.arquillian.junit.InSequence) Test(org.junit.Test)

Aggregations

TakeOffer (io.bisq.api.model.TakeOffer)9 InSequence (org.jboss.arquillian.junit.InSequence)9 Test (org.junit.Test)9 Ignore (org.junit.Ignore)2 OfferDetail (io.bisq.api.model.OfferDetail)1