Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

implement edge dictionary injectable for testing process #405

Merged

Conversation

ysugimoto
Copy link
Owner

@ysugimoto ysugimoto commented Feb 6, 2025

Fixes #404

This PR implements injectable edge dictionary as a table declaration on testing process like simulator configuration.

Configuration

We will define the config.testing.edge_dictionary as the same as config.simulator.edge_dictionary.
Once I thought that we can use config.simulator.edge_dictionary also in the testing process but I decided that the simulator and testing should work independenctly so I divided configuration.

...
testing:
  edge_dictionary:
    foo:
      some: value
...

Changes

And I added a tiny improvement, We only can override dictionary items for existing table, but now we can also inject the edge dictionary as a new table declaration.
This makes the user can inject any edge dictionary even not defined in main VCL (or Fastly Service) - it's better performace for testing because we don't need to fetch the remote edge dictionary - but need to take care that the main VCL will have dependency to the injected dictionary.
Please make sure the tests should pass without dictionary injection before deployments.

@ysugimoto ysugimoto merged commit df77fe4 into main Feb 6, 2025
7 checks passed
@ysugimoto ysugimoto deleted the feature/defineable-edge-dictionary-for-simulator-and-testing branch February 6, 2025 04:49
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature] Enable to Inject Edige Dictionary from testing VCL to main VCL
1 participant