Files
handlebars.js/tests/integration
Jakob Linskeseder c6c6bbb41f Fix bundler issue with webpack 5
As explained in issue #1844 and in issue
https://github.com/webpack/webpack/issues/15007#issuecomment-996615250,
the way we used the `browser`-field was wrong.

The main reason for using the `browser`-field is the requirement of
`require('fs')` in the main-entry-file.
The workaround for this was using `require('handlebars/lib/handlebars')`,
but now it will also work via `require('handlebars')` for bundlers that
respect the `browser`-field.

The `"./runtime"`-config was removed, because it didn't have any effect.
In order to detect regressions, the webpack-integration test was
extended to test with different webpack versions.

Fixes #1174
Closes #1844
2022-05-17 21:09:05 +02:00
..

Add a new integration test by creating a new subfolder

Add a file "test.sh" to that runs the test. "test.sh" should exit with a non-zero exit code and display an error message, if something goes wrong.

  • An integration test should reflect real-world setups that use handlebars.
  • It should compile a minimal template and compare the output to an expected output.
  • It should use "../.." as dependency for Handlebars so that the currently built library is used.

Currently, integration tests are only running on Linux, especially in our CI GitHub action.