Conversation

headlessNode

Description

What is the purpose of this pull request?

This pull request:

  • updates the pre-push git hook to run tests when the source files are modified.
  • If the C source or manifest.json is modified, the native-addons are compiled before running the tests.

Related Issues

Does this pull request have any related issues?

This pull request:

Questions

Any questions for reviewers of this pull request?

Do we need to add support for julia, R or python?.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

No.

Checklist

Please ensure the following tasks are completed before submitting this pull request.


@stdlib-js/reviewers

---
type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes.
report:
  - task: lint_filenames
    status: passed
  - task: lint_editorconfig
    status: passed
  - task: lint_markdown
    status: na
  - task: lint_package_json
    status: na
  - task: lint_repl_help
    status: na
  - task: lint_javascript_src
    status: na
  - task: lint_javascript_cli
    status: na
  - task: lint_javascript_examples
    status: na
  - task: lint_javascript_tests
    status: na
  - task: lint_javascript_benchmarks
    status: na
  - task: lint_python
    status: na
  - task: lint_r
    status: na
  - task: lint_c_src
    status: na
  - task: lint_c_examples
    status: na
  - task: lint_c_benchmarks
    status: na
  - task: lint_c_tests_fixtures
    status: na
  - task: lint_shell
    status: missing_dependencies
  - task: lint_typescript_declarations
    status: na
  - task: lint_typescript_tests
    status: na
  - task: lint_license_headers
    status: passed
---
@headlessNodeheadlessNode added the ToolsIssue or pull request related to project tooling.label Mar 1, 2025
@stdlib-botstdlib-bot added the Needs ReviewA pull request which needs code review.label Mar 1, 2025
Signed-off-by: Muhammad Haris <[email protected]>
@kgryte

Do we need to add support for julia, R or python?.

You asking specifically about when fixtures runners change, correct?

@headlessNode

@kgryte Uh... I was asking about the source but now that I think about it, I think I only saw Fortran source in some of BLAS packages.

But yeah, also when fixtures runners change.

@kgryte

I was asking about the source but now that I think about it, I think I only saw Fortran source in some of BLAS packages.

Only Fortran and C files from the src folder.

Test fixture runners.

Actually, only when the generated fixtures change, not the runners. E.g., fixtures/data.json. Meaning, if a JSON file changes in a fixtures file, we should rerun the tests, but not the runners themselves.

@headlessNode

@kgryte For testing, could you let me know a package which has all of those? i.e. JS, C, Fortran, fixtures

nvm, I greped it.

---
type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes.
report:
  - task: lint_filenames
    status: passed
  - task: lint_editorconfig
    status: passed
  - task: lint_markdown
    status: na
  - task: lint_package_json
    status: na
  - task: lint_repl_help
    status: na
  - task: lint_javascript_src
    status: na
  - task: lint_javascript_cli
    status: na
  - task: lint_javascript_examples
    status: na
  - task: lint_javascript_tests
    status: na
  - task: lint_javascript_benchmarks
    status: na
  - task: lint_python
    status: na
  - task: lint_r
    status: na
  - task: lint_c_src
    status: na
  - task: lint_c_examples
    status: na
  - task: lint_c_benchmarks
    status: na
  - task: lint_c_tests_fixtures
    status: na
  - task: lint_shell
    status: missing_dependencies
  - task: lint_typescript_declarations
    status: na
  - task: lint_typescript_tests
    status: na
  - task: lint_license_headers
    status: passed
---
@headlessNodeheadlessNode requested a review from kgryte March 1, 2025 10:42
@PlaneshifterPlaneshifter added the Potential DuplicateThere might be another pull request resolving the same issue.label Mar 15, 2025
@kgrytekgryte removed the Potential DuplicateThere might be another pull request resolving the same issue.label Mar 17, 2025
Sign up for free to join this conversation on . Already have an account? Sign in to comment
Needs ReviewA pull request which needs code review.ToolsIssue or pull request related to project tooling.
None yet

Successfully merging this pull request may close these issues.

[RFC]: add support to pre-push Git hook to run package tests after changing source files