Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Update generated protocol fixtures folders and their symlinks from dpos to pos #8579

Closed
Tracked by #7244
bobanm opened this issue Jun 12, 2023 · 0 comments
Closed
Tracked by #7244
Assignees
Milestone

Comments

@bobanm
Copy link
Contributor

bobanm commented Jun 12, 2023

Actual behavior

The folders containing generated protocol fixtures were not updated from dpos to pos. Also the symlinks in framework/test/fixtures/ which point to those fixture folders were also not updated:

pos_forger_selection -> ../../../protocol-specs/generator_outputs/dpos_forger_selection
pos_random_seed_generation -> ../../../protocol-specs/generator_outputs/dpos_random_seed_generation
pos_validator_shuffling -> ../../../protocol-specs/generator_outputs/dpos_delegate_shuffling

This is currently not an issue, because both fixtures and symlinks use the old names.

However, when there is a change in protocol and it is needed to re-generate protocol fixtures, running the fixture generator such as protocol-specs/generators/pos_random_seed_generation/index.js will not overwrite the existing fixtures. Instead, it will store the newly generated fixtures in protocol-specs/generator_outputs/pos_random_seed_generation and the symlinks will still point to the old fixtures in dpos folder.

Expected behavior

After generating new protocol fixtures, the tests which use them should use the newly generated version, instead of the old version from dpos folder.

Steps to reproduce

  1. Run protocol-specs/generators/pos_random_seed_generation/index.js
  2. The new fixtures will be created in protocol-specs/generator_outputs/pos_random_seed_generation/
  3. The tests which import fixtures from framework/test/fixtures/ folder will still use old fixtures from dpos_random_seed_generation
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants