Skip to content

Fix Makefile of testint plugin#255

Merged
raphael merged 7 commits into
v3from
testing-make
May 12, 2026
Merged

Fix Makefile of testint plugin#255
raphael merged 7 commits into
v3from
testing-make

Conversation

@tchssk
Copy link
Copy Markdown
Member

@tchssk tchssk commented May 5, 2026

This pull request refactors and improves the testing plugin’s example management and build process, updates generated code to reflect newer tool versions, and introduces better linting and exclusion practices. The changes make it easier to generate, build, and test example services, and ensure that generated files and linting processes are up-to-date and accurate.

Build and Example Management Improvements:

  • Major refactor of testing/Makefile to add explicit gen, example, test, build-examples, and clean targets for generating, building, and testing example services (calculator, httpgrpc, jsonrpc). This replaces the old, less flexible approach and provides clearer, more maintainable commands.
  • Addition of a .golint_exclude file to exclude the examples directory from linting, preventing unnecessary lint errors on example code.

Linting and Formatting Enhancements:

  • The lint target in plugins.mk is updated to exclude .pb.go files (protobuf-generated code) from formatting checks, avoiding false positives and unnecessary formatting errors.

Generated Code Updates:

  • All generated files in testing/examples/calculator/gen and related subdirectories now show updated headers, reflecting the latest version of goa and the new command-line arguments used for code generation. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13]
  • The goa.json file is added to record the goa version used for code generation, supporting better reproducibility.

Minor Documentation and Code Quality:

  • Minor improvements to comments and docstrings for clarity and formatting in test harness code.
  • Minor improvements to error name documentation for generated error types.

These changes collectively improve the maintainability, reliability, and developer experience when working with the testing plugin and its example services.

@tchssk tchssk marked this pull request as ready for review May 5, 2026 14:36
@raphael
Copy link
Copy Markdown
Member

raphael commented May 9, 2026

Thanks for cleaning this up, the new targets make the testing plugin examples much easier to work with.

I pulled the PR locally and ran the new paths from a clean archive of the branch:

  • make -C testing test
  • make -C testing lint
  • make -C testing build-examples
  • make -C testing all

Everything passed.

The main thing I noticed is that top-level CI still does not exercise this, since testing is not in the root PLUGINS list. That means make ci can stay green even if testing/Makefile regresses. Could you either add testing to PLUGINS or add a dedicated CI step for make -C testing all?

Tiny cleanup: because testing/Makefile includes ../plugins.mk before redefining test, make prints an override warning on every target. It does not break anything, but it would be nice to avoid the noise while touching this.

@tchssk
Copy link
Copy Markdown
Member Author

tchssk commented May 10, 2026

I added testing to PLUGINS. Everything passed, so it's ready to merge.

The override warning isn't limited to testing, so it would be better to fix it in a separate pull request. It seems like it could be resolved by using the double colon rule (::).

@raphael
Copy link
Copy Markdown
Member

raphael commented May 12, 2026

Yeah that makes sense, thank you!

@raphael raphael merged commit 70b1733 into v3 May 12, 2026
5 checks passed
@raphael raphael deleted the testing-make branch May 12, 2026 17:27
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.

2 participants