AssertJ fluent assertions for QuickFix/J


License

License

GroupId

GroupId

io.allune
ArtifactId

ArtifactId

assertj-quickfixj
Last Version

Last Version

1.0.0-RC1
Release Date

Release Date

Type

Type

jar
Description

Description

AssertJ fluent assertions for QuickFix/J
AssertJ fluent assertions for QuickFix/J
Project URL

Project URL

https://github.com/esanchezros/assertj-quickfixj
Source Code Management

Source Code Management

https://github.com/esanchezros/assertj-quickfixj

Download assertj-quickfixj

How to add to project

<!-- https://jarcasting.com/artifacts/io.allune/assertj-quickfixj/ -->
<dependency>
    <groupId>io.allune</groupId>
    <artifactId>assertj-quickfixj</artifactId>
    <version>1.0.0-RC1</version>
</dependency>
// https://jarcasting.com/artifacts/io.allune/assertj-quickfixj/
implementation 'io.allune:assertj-quickfixj:1.0.0-RC1'
// https://jarcasting.com/artifacts/io.allune/assertj-quickfixj/
implementation ("io.allune:assertj-quickfixj:1.0.0-RC1")
'io.allune:assertj-quickfixj:jar:1.0.0-RC1'
<dependency org="io.allune" name="assertj-quickfixj" rev="1.0.0-RC1">
  <artifact name="assertj-quickfixj" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.allune', module='assertj-quickfixj', version='1.0.0-RC1')
)
libraryDependencies += "io.allune" % "assertj-quickfixj" % "1.0.0-RC1"
[io.allune/assertj-quickfixj "1.0.0-RC1"]

Dependencies

compile (1)

Group / Artifact Type Version
org.assertj : assertj-core jar [3.5.0, 3.99.0]

provided (3)

Group / Artifact Type Version
org.quickfixj : quickfixj-core jar 2.2.0
org.quickfixj : quickfixj-messages-all jar 2.2.0
org.projectlombok : lombok jar 1.18.8

test (2)

Group / Artifact Type Version
junit : junit jar 4.12
org.mockito : mockito-core jar 2.18.3

Project Modules

There are no modules declared in this project.

AssertJ fluent assertions for QuickFix/J (Release Candidate)

// Given
Message message = new Message(
        "8=FIX.4.0\u00019=122\u000135=D\u000134=215\u000149=CLIENT12\u000152=20100225-19:41:57.316\u000138=1000\u000156=B\u00011=Marcel\u000111=13346\u000121=1\u000140=2\u000144=5\u000154=1\u000155=GBP/USD\u000159=0\u000160=20100225-19:39:52.020\u000110=074\u0001");

// When/Then
//@formatter:off
assertThat(message)
        .hasFieldValue(Account.FIELD, "Marcel")
        .hasFieldValue(ClOrdID.FIELD, "13346")
        .hasFieldValue(Side.FIELD, "1")
        .hasFieldValue(Symbol.FIELD, "GBP/USD")
        .hasFieldValue(OrdType.FIELD, "2");
//@formatter:on



// Given
Message message = new Message(
        "8=FIX.4.0\u00019=122\u000135=D\u000134=215\u000149=CLIENT12\u000152=20100225-19:41:57.316\u000138=1000\u000156=B\u00011=Marcel\u000111=13346\u000121=1\u000140=2\u000144=5\u000154=1\u000155=GBP/USD\u000159=0\u000160=20100225-19:39:52.020\u000110=074\u0001");

// When/Then
//@formatter:off
assertThat(message)
        .isVersion40()
        .header()
            .hasField(BeginString.FIELD)
            .hasField(BodyLength.FIELD)
            .hasField(MsgType.FIELD)
            .hasField(MsgSeqNum.FIELD)
            .hasField(SenderCompID.FIELD)
            .hasField(SendingTime.FIELD)
            .hasField(TargetCompID.FIELD)
        .and()
        .trailer()
            .hasField(CheckSum.FIELD)
        .and()
            .hasField(Account.FIELD)
            .hasField(ClOrdID.FIELD)
            .hasField(Side.FIELD)
            .hasField(Symbol.FIELD)
            .hasField(OrdType.FIELD)
;
//@formatter:on

Versions

Version
1.0.0-RC1