-
Notifications
You must be signed in to change notification settings - Fork 33
[Testing] Prefer pre-generated keys in tests #614
Copy link
Copy link
Open
Labels
testingDefining, adding, automating or modifying testsDefining, adding, automating or modifying tests
Milestone
Description
Objective
Enabling faster and more deterministic tests.
Origin Document
Goals
- Ability to pre-generate an arbitrary number of keys
- Pre-generated keys are accessible via vanilla go imports (see: storj/common
testidentitypkg) - Pre-generated keys are tracked in version control (same keys everywhere: devs, CI, etc.)
Deliverable
-
Add a make target which generates the keys, output as go source code.Load existing pre-generated keys from private-keys.yaml - Add a package (e.g.
testkeys; also see [Testing] Organizing test utilities package(s) #609) which exports a means by which to retrieve the pre-generated ascryptoPocket.PrivateKeys- I think the iterator pattern is nice for this because it fits well with our use case as we typically don't want to reuse keys (identity), across nodes for example.
- It would be prudent to ensure that we can also retrieve specific identities, I think via index should suffice.
Non-goals / Non-deliverables
- Refactoring existing tests to use pre-generated identities.
General issue deliverables
- Update the appropriate CHANGELOG(s)
- Update any relevant local/global README(s)
- Update relevant source code tree explanations
- Add or update any relevant or supporting mermaid diagrams
Testing Methodology
- All tests:
make test_all - LocalNet: verify a
LocalNetis still functioning correctly by following the instructions at docs/development/README.md
Creator: @bryanchriswhite
Co-Owners: @deblasis
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
testingDefining, adding, automating or modifying testsDefining, adding, automating or modifying tests
Type
Projects
Status
Backlog
