Require test argument (#196)

* Require test argument

* Increase tx timeout and channel limits

* Add default arguments for tests

* Fix tests

* Fix tests
This commit is contained in:
Omar
2025-10-27 03:17:47 +03:00
committed by GitHub
parent b71445b632
commit fefea17c8e
7 changed files with 38 additions and 14 deletions
+2 -2
View File
@@ -41,7 +41,7 @@ pub struct ReportAggregator {
impl ReportAggregator {
pub fn new(context: Context) -> Self {
let (runner_tx, runner_rx) = unbounded_channel::<RunnerEvent>();
let (listener_tx, _) = channel::<ReporterEvent>(1024);
let (listener_tx, _) = channel::<ReporterEvent>(0xFFFF);
Self {
report: Report::new(context),
remaining_cases: Default::default(),
@@ -64,7 +64,7 @@ impl ReportAggregator {
debug!("Starting to aggregate report");
while let Some(event) = self.runner_rx.recv().await {
debug!(?event, "Received Event");
debug!(event = event.variant_name(), "Received Event");
match event {
RunnerEvent::SubscribeToEvents(event) => {
self.handle_subscribe_to_events_event(*event);
+10
View File
@@ -347,6 +347,16 @@ macro_rules! define_event {
),*
}
impl $ident {
pub fn variant_name(&self) -> &'static str {
match self {
$(
Self::$variant_ident { .. } => stringify!($variant_ident)
),*
}
}
}
$(
#[derive(Debug)]
$(#[$variant_meta])*