Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Add test implementations for the exporter-api #9319

Closed
Tracked by #8609
npepinpe opened this issue May 6, 2022 · 0 comments · Fixed by #9326
Closed
Tracked by #8609

Add test implementations for the exporter-api #9319

npepinpe opened this issue May 6, 2022 · 0 comments · Fixed by #9326
Assignees
Labels
area/test Marks an issue as improving or extending the test coverage of the project kind/toil Categorizes an issue or PR as general maintenance, i.e. cleanup, refactoring, etc. version:8.1.0-alpha2 version:8.1.0 Marks an issue as being completely or in parts released in 8.1.0

Comments

@npepinpe
Copy link
Member

npepinpe commented May 6, 2022

Description

In order to test exporters with a simplified set up, it's useful to just create your own exporter instance, configure it, pass it a controllable context, etc. This avoids having to setup a whole broker around your exporter just to test it.

This is achievable using mocks, however as the usage of these mocks grow, it means any time the interface changes we have to update all the mocks everywhere. It's much easier to refactor these things, and to write tests, with controlled implementations.

The goal would be to add implementations of the all the interfaces in exporter-api, minus the Exporter interface itself.

I would propose adding a new special purpose module for this to move away from having catch all modules (e.g. util, test-util), but I'm happy to comply and keep these utilities there.

@npepinpe npepinpe added kind/toil Categorizes an issue or PR as general maintenance, i.e. cleanup, refactoring, etc. team/process-automation area/test Marks an issue as improving or extending the test coverage of the project labels May 6, 2022
@npepinpe npepinpe self-assigned this May 6, 2022
@Zelldon Zelldon added the version:8.1.0 Marks an issue as being completely or in parts released in 8.1.0 label Oct 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/test Marks an issue as improving or extending the test coverage of the project kind/toil Categorizes an issue or PR as general maintenance, i.e. cleanup, refactoring, etc. version:8.1.0-alpha2 version:8.1.0 Marks an issue as being completely or in parts released in 8.1.0
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants