@@ -5,16 +5,11 @@ import (
55
66 "github.com/stretchr/testify/require"
77 "go.temporal.io/server/chasm"
8- "go.temporal.io/server/common/namespace"
98)
109
1110func TestTimeSkippingFastForwardNotifier (t * testing.T ) {
12- // The notifier's hash covers only (namespace, workflowID), so keys differing solely by
13- // archetype land on the same lock shard and stay distinct by struct equality alone.
14- oneShardByWorkflow := func (namespace.ID , string ) int32 { return 1 }
15-
1611 t .Run ("archetype isolates executions sharing a business id" , func (t * testing.T ) {
17- n := NewTimeSkippingFastForwardNotifier (oneShardByWorkflow )
12+ n := NewTimeSkippingFastForwardNotifier ()
1813 workflowKey := NewTimeSkippingNotificationKey ("ns" , "wf" , chasm .WorkflowArchetypeID )
1914 schedulerKey := NewTimeSkippingNotificationKey ("ns" , "wf" , chasm .SchedulerArchetypeID )
2015
@@ -38,7 +33,7 @@ func TestTimeSkippingFastForwardNotifier(t *testing.T) {
3833 // The waiter always names the workflow archetype while the publisher forwards whatever the
3934 // execution carries, so a pre-archetype record (unspecified) must reach the workflow waiter.
4035 t .Run ("unspecified archetype is normalized to workflow" , func (t * testing.T ) {
41- n := NewTimeSkippingFastForwardNotifier (oneShardByWorkflow )
36+ n := NewTimeSkippingFastForwardNotifier ()
4237 require .Equal (t ,
4338 NewTimeSkippingNotificationKey ("ns" , "wf" , chasm .WorkflowArchetypeID ),
4439 NewTimeSkippingNotificationKey ("ns" , "wf" , chasm .UnspecifiedArchetypeID ))
@@ -71,7 +66,7 @@ func TestTimeSkippingFastForwardNotifier(t *testing.T) {
7166 })
7267
7368 t .Run ("keys match by value, not identity" , func (t * testing.T ) {
74- n := NewTimeSkippingFastForwardNotifier (oneShardByWorkflow )
69+ n := NewTimeSkippingFastForwardNotifier ()
7570 _ , ch , err := n .Watch (NewTimeSkippingNotificationKey ("ns" , "wf" , chasm .WorkflowArchetypeID ))
7671 require .NoError (t , err )
7772
0 commit comments