Skip to content

Conversation

@AlanRostem
Copy link
Collaborator

Fixes #159

@AlanRostem AlanRostem linked an issue Jan 16, 2025 that may be closed by this pull request
We skip the / separator for the first field since this is added by
the t.Run(name) call.
Copy link
Member

@meling meling left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks very nice!! A few minor nits and one open question...

return nil, err
}
opt.SetTreeOptions(e.hostCfg.BranchFactor, e.hostCfg.TreePositions, e.hostCfg.TreeDelta)
// opt.SetTreeOptions(e.hostCfg.BranchFactor, e.hostCfg.TreePositions, e.hostCfg.TreeDelta)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep or delete?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keep! I forgot to uncomment this. On that note, we still might want to remove this line in a different branch since the tree values don't need to be set here when they can come from replicaOpts in NewExperiment instead

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Opened #168 to address this problem and some other stuff

t.Run(test.Name([]string{"consensus", "crypto", "byzantine", "mods"}, tt.consensus, tt.crypto, tt.byzantine, tt.mods), func(t *testing.T) {
var replicaOpts *orchestrationpb.ReplicaOpts
if slices.Contains(tt.mods, "kauri") {
replicaOpts = makeTreeReplicaOpts(tt.consensus, tt.crypto, tt.mods, 7, 2, tt.randomTree)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should make 7, 2 be part of the tests struct, and leave it unspecified (0) for the non-kauri tests.

mods []string
randomTree bool
}{
{consensus: "chainedhotstuff", crypto: "ecdsa", byzantine: "", mods: nil},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should remove mods: nil from lines that don't need it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the same applies to byzantine I think; it will be the zero value anyway.

workerProxy := orchestration.NewRemoteWorker(protostream.NewWriter(controllerStream), protostream.NewReader(controllerStream))
worker := orchestration.NewWorker(protostream.NewWriter(workerStream), protostream.NewReader(workerStream), metrics.NopLogger(), nil, 0)

cfg := config.NewLocal(7, 2)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hardcoded?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should these be moved into the tests struct?

Copy link
Member

@meling meling left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one also appears to conflict heavily with #170 in orchestration_test.go. I suggest to salvage what's relevant in this one and move it to #170.

@AlanRostem AlanRostem merged commit 32a55d4 into master Jan 24, 2025
4 checks passed
@meling meling deleted the 159-testorchestration-cleanup branch January 24, 2025 11:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Chore: Make TestOrchestration subtests follow standard testing style

3 participants