Skip to content

Commit e615ef3

Browse files
committed
comments and diff
1 parent 5092e70 commit e615ef3

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

crates/audit/tests/integration_tests.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ use tips_audit::{
55
storage::{BundleEventS3Reader, S3EventReaderWriter},
66
types::{BundleEvent, DropReason},
77
};
8-
use tips_core::test_utils::create_test_bundle;
8+
use tips_core::test_utils::create_bundle_from_txn_data;
99
use uuid::Uuid;
1010
mod common;
1111
use common::TestHarness;
@@ -23,7 +23,7 @@ async fn test_kafka_publisher_s3_archiver_integration()
2323
let test_events = vec![
2424
BundleEvent::Received {
2525
bundle_id: test_bundle_id,
26-
bundle: Box::new(create_test_bundle(vec![], None, None, None)),
26+
bundle: Box::new(create_bundle_from_txn_data()),
2727
},
2828
BundleEvent::Dropped {
2929
bundle_id: test_bundle_id,

crates/audit/tests/s3_test.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ use uuid::Uuid;
1010

1111
mod common;
1212
use common::TestHarness;
13-
use tips_core::test_utils::TXN_HASH;
14-
use tips_core::test_utils::create_bundle_from_txn_data;
13+
use tips_core::test_utils::{TXN_HASH, create_bundle_from_txn_data};
1514

1615
fn create_test_event(key: &str, timestamp: i64, bundle_event: BundleEvent) -> Event {
1716
Event {

crates/core/src/types.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ use uuid::Uuid;
1111
/// Block time in microseconds
1212
pub const BLOCK_TIME: u128 = 2_000_000;
1313

14+
/// `Bundle` is the type that mirrors `EthSendBundle` and is used for the API.
1415
#[derive(Default, Debug, Serialize, Deserialize, Clone, PartialEq, Eq)]
1516
#[serde(rename_all = "camelCase")]
1617
pub struct Bundle {
@@ -57,6 +58,7 @@ pub struct Bundle {
5758
pub dropping_tx_hashes: Vec<TxHash>,
5859
}
5960

61+
/// `ParsedBundle` is the type that contains utility methods for the `Bundle` type.
6062
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
6163
pub struct ParsedBundle {
6264
pub txs: Vec<Recovered<OpTxEnvelope>>,
@@ -129,6 +131,7 @@ pub struct CancelBundle {
129131
pub replacement_uuid: String,
130132
}
131133

134+
/// `AcceptedBundle` is the type that is sent over the wire.
132135
#[derive(Debug, Clone, Serialize, Deserialize)]
133136
pub struct AcceptedBundle {
134137
pub uuid: Uuid,

0 commit comments

Comments
 (0)