Skip to content

Commit

Permalink
more chaining
Browse files Browse the repository at this point in the history
  • Loading branch information
heavycrystal committed Feb 8, 2024
1 parent f768ba9 commit 30bac25
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions flow/e2e/postgres/peer_flow_pg_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1118,6 +1118,7 @@ func (s PeerFlowE2ETestSuitePG) Test_Dynamic_Mirror_Config_Via_Signals() {
dstTable1Name := s.attachSchemaSuffix("test_dynconfig_1_dst")
dstTable2Name := s.attachSchemaSuffix("test_dynconfig_2_dst")
sentPause := false
isPaused := false
sentUpdate := false

_, err := s.conn.Exec(context.Background(), fmt.Sprintf(`
Expand Down Expand Up @@ -1200,6 +1201,7 @@ func (s PeerFlowE2ETestSuitePG) Test_Dynamic_Mirror_Config_Via_Signals() {
if flowStatus != protos.FlowStatus_STATUS_PAUSED {
return false
}
isPaused = true
env.SignalWorkflow(shared.CDCDynamicPropertiesSignalName, &protos.CDCFlowConfigUpdate{
IdleTimeout: 14,
BatchSize: 12,
Expand Down Expand Up @@ -1253,8 +1255,8 @@ func (s PeerFlowE2ETestSuitePG) Test_Dynamic_Mirror_Config_Via_Signals() {
e2e.EnvWaitFor(s.t, env, 1*time.Minute, "paused workflow", func() bool {
// keep adding 1 more row - guarantee finishing another sync
addRows(1)
flowStatus := getFlowStatus()
return flowStatus == protos.FlowStatus_STATUS_PAUSED
// isPaused - set from the WaitFor that sends update signal
return isPaused
})
e2e.EnvWaitFor(s.t, env, 1*time.Minute, "normalize 1 record - first table", func() bool {
return s.comparePGTables(srcTable1Name, dstTable1Name, "id,t") == nil
Expand Down

0 comments on commit 30bac25

Please sign in to comment.