Skip to content
This repository was archived by the owner on Feb 6, 2026. It is now read-only.

Commit 4dfc790

Browse files
authored
Merge pull request #8332 from systeminit/test-improvements
chore: improve dal integration test performance
2 parents 67bf979 + fd02731 commit 4dfc790

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+281
-209
lines changed

lib/dal/tests/integration_test/action.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ async fn set_state(ctx: &mut DalContext) -> Result<()> {
134134
Ok(())
135135
}
136136

137-
#[test]
137+
#[test(enable_veritech)]
138138
async fn run(ctx: &mut DalContext) -> Result<()> {
139139
let component =
140140
create_component_for_default_schema_name_in_default_view(ctx, "swifty", "shake it off")
@@ -190,7 +190,7 @@ async fn auto_queue_creation(ctx: &mut DalContext) -> Result<()> {
190190
Ok(())
191191
}
192192

193-
#[test]
193+
#[test(enable_veritech)]
194194
async fn auto_queue_update(ctx: &mut DalContext) -> Result<()> {
195195
// ======================================================
196196
// Creating a component should enqueue a create action
@@ -327,7 +327,7 @@ async fn auto_queue_update(ctx: &mut DalContext) -> Result<()> {
327327
Ok(())
328328
}
329329

330-
#[test]
330+
#[test(enable_veritech)]
331331
async fn refresh_actions_run_where_they_should(ctx: &mut DalContext) -> Result<()> {
332332
// small even schema can be used to test this!
333333
// First, we'll create a new component and apply (and wait for the create action to run)
@@ -436,7 +436,7 @@ async fn refresh_actions_run_where_they_should(ctx: &mut DalContext) -> Result<(
436436
Ok(())
437437
}
438438

439-
#[test]
439+
#[test(enable_veritech)]
440440
async fn resource_value_propagation_subscriptions_works(ctx: &mut DalContext) -> Result<()> {
441441
// create 2 variants A & B where A has a resource_value prop that B is subscribed to
442442
let component_a_code_definition = r#"

lib/dal/tests/integration_test/action/schema_level.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ use dal_test::{
2222
};
2323
use pretty_assertions_sorted::assert_eq;
2424

25-
#[test]
25+
#[test(enable_veritech)]
2626
async fn schema_level_action_prototype(ctx: &mut DalContext) -> Result<()> {
2727
let schema = Schema::get_by_name(ctx, "swifty").await?;
2828
let default_schema_variant_id = Schema::default_variant_id(ctx, schema.id()).await?;

lib/dal/tests/integration_test/asset.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ use dal_test::{
1515
test,
1616
};
1717

18-
#[test]
18+
#[test(enable_veritech)]
1919
async fn asset_func_execution_papercuts(ctx: &mut DalContext) {
2020
let (schema_name, unstable_schema_variant_id) = {
2121
let schema_variant = VariantAuthoringClient::create_schema_and_variant(

lib/dal/tests/integration_test/attribute_value.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ async fn arguments_for_prototype_function_execution(ctx: &mut DalContext) -> Res
4545
Ok(())
4646
}
4747

48-
#[test]
48+
#[test(enable_veritech)]
4949
async fn attribute_value_path(ctx: &mut DalContext) -> Result<()> {
5050
// Create a component and commit. For context, the test exclusive schema has the identity
5151
// function set on "/root/domain/name" with an input from "/root/si/name". We need to ensure
@@ -128,7 +128,7 @@ async fn attribute_value_path(ctx: &mut DalContext) -> Result<()> {
128128
Ok(())
129129
}
130130

131-
#[test]
131+
#[test(enable_veritech)]
132132
async fn update_object_multiplayer(ctx: &mut DalContext) -> Result<()> {
133133
// Create a variant that will be in all three change sets
134134
variant::create(

lib/dal/tests/integration_test/attribute_value/subscription.rs

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ use si_id::ComponentId;
2727
pub mod default_subscriptions;
2828

2929
// AV subscribes to name AV on same component
30-
#[test]
30+
#[test(enable_veritech)]
3131
async fn subscribe_to_name_on_same_component(ctx: &mut DalContext) -> Result<()> {
3232
// Make a variant with a Value prop
3333
variant::create(
@@ -75,7 +75,7 @@ async fn subscribe_to_name_on_same_component(ctx: &mut DalContext) -> Result<()>
7575
}
7676

7777
// AV subscribes to AV on same component
78-
#[test]
78+
#[test(enable_veritech)]
7979
async fn subscribe_to_string(ctx: &mut DalContext) -> Result<()> {
8080
create_testy_variant(ctx).await?;
8181

@@ -118,7 +118,7 @@ async fn subscribe_to_string(ctx: &mut DalContext) -> Result<()> {
118118
}
119119

120120
// AV subscribes to array element of another AV
121-
#[test]
121+
#[test(enable_veritech)]
122122
async fn subscribe_to_array_element(ctx: &mut DalContext) -> Result<()> {
123123
create_testy_variant(ctx).await?;
124124

@@ -164,7 +164,7 @@ async fn subscribe_to_array_element(ctx: &mut DalContext) -> Result<()> {
164164
}
165165

166166
// AV subscribes to map element of another AV
167-
#[test]
167+
#[test(enable_veritech)]
168168
async fn subscribe_to_map_element(ctx: &mut DalContext) -> Result<()> {
169169
create_testy_variant(ctx).await?;
170170

@@ -214,7 +214,7 @@ async fn subscribe_to_map_element(ctx: &mut DalContext) -> Result<()> {
214214
}
215215

216216
// Two different subscriptions to different values on the same component (tests dirty logic)
217-
#[test]
217+
#[test(enable_veritech)]
218218
async fn subscribe_to_two_values(ctx: &mut DalContext) -> Result<()> {
219219
create_testy_variant(ctx).await?;
220220

@@ -275,7 +275,7 @@ async fn subscribe_to_two_values(ctx: &mut DalContext) -> Result<()> {
275275
Ok(())
276276
}
277277

278-
#[test]
278+
#[test(enable_veritech)]
279279
async fn delete_component_with_subscriptions_correction(ctx: &mut DalContext) -> Result<()> {
280280
create_testy_variant(ctx).await?;
281281

@@ -332,7 +332,7 @@ async fn delete_component_with_subscriptions_correction(ctx: &mut DalContext) ->
332332
Ok(())
333333
}
334334

335-
#[test]
335+
#[test(enable_veritech)]
336336
async fn array_subscription(ctx: &mut DalContext) -> Result<()> {
337337
create_testy_variant(ctx).await?;
338338

@@ -367,7 +367,7 @@ async fn array_subscription(ctx: &mut DalContext) -> Result<()> {
367367
Ok(())
368368
}
369369

370-
#[test]
370+
#[test(enable_veritech)]
371371
async fn array_item_subscriptions(ctx: &mut DalContext) -> Result<()> {
372372
create_testy_variant(ctx).await?;
373373

@@ -411,7 +411,7 @@ async fn array_item_subscriptions(ctx: &mut DalContext) -> Result<()> {
411411
Ok(())
412412
}
413413

414-
#[test]
414+
#[test(enable_veritech)]
415415
async fn subscription_object_to_map(ctx: &mut DalContext) -> Result<()> {
416416
create_testy_variant(ctx).await?;
417417

@@ -443,7 +443,7 @@ async fn subscription_object_to_map(ctx: &mut DalContext) -> Result<()> {
443443
Ok(())
444444
}
445445

446-
#[test]
446+
#[test(enable_veritech)]
447447
async fn subscription_map_to_object(ctx: &mut DalContext) -> Result<()> {
448448
create_testy_variant(ctx).await?;
449449

@@ -475,7 +475,7 @@ async fn subscription_map_to_object(ctx: &mut DalContext) -> Result<()> {
475475
Ok(())
476476
}
477477

478-
#[test]
478+
#[test(enable_veritech)]
479479
async fn subscription_json_to_string(ctx: &mut DalContext) -> Result<()> {
480480
create_testy_variant(ctx).await?;
481481

@@ -502,7 +502,7 @@ async fn subscription_json_to_string(ctx: &mut DalContext) -> Result<()> {
502502
Ok(())
503503
}
504504

505-
#[test]
505+
#[test(enable_veritech)]
506506
async fn subscription_string_to_json(ctx: &mut DalContext) -> Result<()> {
507507
create_testy_variant(ctx).await?;
508508

@@ -529,7 +529,7 @@ async fn subscription_string_to_json(ctx: &mut DalContext) -> Result<()> {
529529
Ok(())
530530
}
531531

532-
#[test]
532+
#[test(enable_veritech)]
533533
async fn subscription_type_mismatch_array_to_single(ctx: &mut DalContext) -> Result<()> {
534534
create_testy_variant(ctx).await?;
535535

@@ -554,7 +554,7 @@ async fn subscription_type_mismatch_array_to_single(ctx: &mut DalContext) -> Res
554554
Ok(())
555555
}
556556

557-
#[test]
557+
#[test(enable_veritech)]
558558
async fn subscription_type_mismatch_single_to_array(ctx: &mut DalContext) -> Result<()> {
559559
create_testy_variant(ctx).await?;
560560

@@ -579,7 +579,7 @@ async fn subscription_type_mismatch_single_to_array(ctx: &mut DalContext) -> Res
579579
Ok(())
580580
}
581581

582-
#[test]
582+
#[test(enable_veritech)]
583583
async fn delete_subscribed_to_array_item(ctx: &mut DalContext) -> Result<()> {
584584
create_testy_variant(ctx).await?;
585585

@@ -634,7 +634,7 @@ async fn delete_subscribed_to_array_item(ctx: &mut DalContext) -> Result<()> {
634634
Ok(())
635635
}
636636

637-
#[test]
637+
#[test(enable_veritech)]
638638
async fn subscribe_with_custom_function(ctx: &mut DalContext) -> Result<()> {
639639
create_testy_variant(ctx).await?;
640640
let func = FuncAuthoringClient::create_new_transformation_func(
@@ -692,7 +692,7 @@ async fn subscribe_with_custom_function(ctx: &mut DalContext) -> Result<()> {
692692
Ok(())
693693
}
694694

695-
#[test]
695+
#[test(enable_veritech)]
696696
async fn remove_subscribed_component(ctx: &mut DalContext) -> Result<()> {
697697
create_testy_variant(ctx).await?;
698698

@@ -738,7 +738,7 @@ async fn remove_subscribed_component(ctx: &mut DalContext) -> Result<()> {
738738
Ok(())
739739
}
740740

741-
#[test]
741+
#[test(enable_veritech)]
742742
async fn subscription_cycles(ctx: &mut DalContext) -> Result<()> {
743743
create_testy_variant(ctx).await?;
744744
component::create(ctx, "testy", "subscriber").await?;
@@ -863,7 +863,7 @@ fn extract_edges(graph: &SubscriptionGraph) -> BTreeSet<(ComponentId, ComponentI
863863
edges
864864
}
865865

866-
#[test]
866+
#[test(enable_veritech)]
867867
async fn subscription_graph_constructors_produce_identical_results(
868868
ctx: &mut DalContext,
869869
) -> Result<()> {

lib/dal/tests/integration_test/attribute_value/subscription/default_subscriptions.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ use dal_test::{
3030
};
3131
use pretty_assertions_sorted::assert_eq;
3232

33-
#[test]
33+
#[test(enable_veritech)]
3434
async fn test_set_as_default_subscription_source(ctx: &DalContext) -> Result<()> {
3535
let (_, _, default_dest_a_variant_id, _) = variants_with_prop_suggestions(ctx).await?;
3636

@@ -234,7 +234,7 @@ async fn test_set_as_default_subscription_source(ctx: &DalContext) -> Result<()>
234234
Ok(())
235235
}
236236

237-
#[test]
237+
#[test(enable_veritech)]
238238
async fn test_is_same_type_as(ctx: &DalContext) -> Result<()> {
239239
variants_with_prop_suggestions(ctx).await?;
240240

lib/dal/tests/integration_test/attributes.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ use si_events::{
4141

4242
// Test that updating attributes sets them (and their parents) correctly, but leaves default
4343
// values and other values alone.
44-
#[test]
44+
#[test(enable_veritech)]
4545
async fn update_attributes(ctx: &DalContext) -> Result<()> {
4646
variant::create(
4747
ctx,
@@ -131,7 +131,7 @@ async fn update_attributes(ctx: &DalContext) -> Result<()> {
131131

132132
// Test that updating an attribute value via the new subscription interface correctly enqueues
133133
// update actions
134-
#[test]
134+
#[test(enable_veritech)]
135135
async fn update_attributes_enqueues_update_fn(ctx: &mut DalContext) -> Result<()> {
136136
// ======================================================
137137
// Creating a component should enqueue a create action
@@ -229,7 +229,7 @@ async fn update_attributes_enqueues_update_fn(ctx: &mut DalContext) -> Result<()
229229

230230
// Test that attribute updates are processed in the order they are specified sets them (and their parents) correctly, but leaves default
231231
// values and other values alone.
232-
#[test]
232+
#[test(enable_veritech)]
233233
async fn update_attributes_runs_in_order_and_allows_duplicates(ctx: &mut DalContext) -> Result<()> {
234234
variant::create(
235235
ctx,
@@ -282,7 +282,7 @@ async fn update_attributes_runs_in_order_and_allows_duplicates(ctx: &mut DalCont
282282
Ok(())
283283
}
284284

285-
#[test]
285+
#[test(enable_veritech)]
286286
async fn update_attributes_serializes_json(ctx: &mut DalContext) -> Result<()> {
287287
variant::create(
288288
ctx,
@@ -357,7 +357,7 @@ async fn update_attributes_serializes_json(ctx: &mut DalContext) -> Result<()> {
357357

358358
// Test that attribute updates are processed in the order they are specified sets them (and their parents) correctly, but leaves default
359359
// values and other values alone.
360-
#[test]
360+
#[test(enable_veritech)]
361361
async fn component_sources_in_order(ctx: &mut DalContext) -> Result<()> {
362362
variant::create(
363363
ctx,
@@ -495,7 +495,7 @@ async fn component_sources_in_order(ctx: &mut DalContext) -> Result<()> {
495495

496496
// Test that updating attributes sets them (and their parents) correctly, but leaves default
497497
// values and other values alone.
498-
#[test]
498+
#[test(enable_veritech)]
499499
async fn update_attribute_child_of_subscription(ctx: &mut DalContext) -> Result<()> {
500500
variant::create(
501501
ctx,
@@ -649,7 +649,7 @@ async fn update_attribute_child_of_subscription(ctx: &mut DalContext) -> Result<
649649
/// This tests the fix for a bug where use_default_prototype was calling update(None)
650650
/// which created a si:Unset component prototype BEFORE removing the manual override,
651651
/// causing the component prototype to remain instead of reverting to the schema variant prototype.
652-
#[test]
652+
#[test(enable_veritech)]
653653
async fn unset_manual_override_reverts_to_default(ctx: &mut DalContext) -> Result<()> {
654654
// Create a schema with a default value
655655
variant::create(
@@ -732,7 +732,7 @@ async fn unset_manual_override_reverts_to_default(ctx: &mut DalContext) -> Resul
732732

733733
/// Test that unsetting a value that was never manually overridden creates a si:Unset component prototype.
734734
/// This tests the else branch of use_default_prototype where no component prototype exists.
735-
#[test]
735+
#[test(enable_veritech)]
736736
async fn unset_value_without_existing_override_creates_unset_prototype(
737737
ctx: &mut DalContext,
738738
) -> Result<()> {

lib/dal/tests/integration_test/audit_logging.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const STREAM_RETRY_INTERVAL_MILLISECONDS: u64 = 100;
3030

3131
const SIZE: usize = 200;
3232

33-
#[test]
33+
#[test(enable_veritech, enable_forklift)]
3434
async fn round_trip(ctx: &mut DalContext, audit_database_context: AuditDatabaseContext) {
3535
let context = audit_database_context;
3636

File renamed without changes.

lib/dal/tests/integration_test/schema/variant/authoring/clone_variant.rs renamed to lib/dal/tests/integration_test/authoring/clone_variant.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use dal::{
77
};
88
use dal_test::test;
99

10-
#[test]
10+
#[test(enable_veritech)]
1111
async fn clone_variant(ctx: &mut DalContext) {
1212
let new_change_set = ChangeSet::fork_head(ctx, "new change set")
1313
.await

0 commit comments

Comments
 (0)