Skip to content

Commit 4f8d463

Browse files
committed
Add another quote tick stub
1 parent 3df7693 commit 4f8d463

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

nautilus_core/model/src/data/quote.rs

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,9 +175,23 @@ pub mod stubs {
175175
use crate::{
176176
data::quote::QuoteTick,
177177
identifiers::instrument_id::InstrumentId,
178+
instruments::{currency_pair::CurrencyPair, stubs::*},
178179
types::{price::Price, quantity::Quantity},
179180
};
180181

182+
#[fixture]
183+
pub fn quote_tick_audusd_sim(audusd_sim: CurrencyPair) -> QuoteTick {
184+
QuoteTick {
185+
instrument_id: audusd_sim.id,
186+
bid_price: Price::from("1.00000"),
187+
ask_price: Price::from("1.00000"),
188+
bid_size: Quantity::from(100_000),
189+
ask_size: Quantity::from(100_000),
190+
ts_event: UnixNanos::default(),
191+
ts_init: UnixNanos::from(1),
192+
}
193+
}
194+
181195
#[fixture]
182196
pub fn quote_tick_ethusdt_binance() -> QuoteTick {
183197
QuoteTick {
@@ -186,7 +200,7 @@ pub mod stubs {
186200
ask_price: Price::from("10001.0000"),
187201
bid_size: Quantity::from("1.00000000"),
188202
ask_size: Quantity::from("1.00000000"),
189-
ts_event: UnixNanos::from(0),
203+
ts_event: UnixNanos::default(),
190204
ts_init: UnixNanos::from(1),
191205
}
192206
}

0 commit comments

Comments
 (0)