capricorn86 / happy-dom

A JavaScript implementation of a web browser without its graphical user interface
MIT License
3.09k stars 185 forks source link

Fix a bug in createTextNode when the data argument is a non-string #1384

Closed odanado closed 3 months ago

odanado commented 3 months ago

Close #1380

Run in Chrome:

 2024-04-06 1 30 54

Run in Safari:

 2024-04-06 1 31 22

Run in Firefox:

 2024-04-06 1 33 02
odanado commented 3 months ago
   FAIL  test/fetch/SyncFetch.test.ts > SyncFetch > send() > Updates cache after a failed revalidation with a "If-Modified-Since" request for a GET response with "Cache-Control" set to a "max-age".
  AssertionError: expected 'some text' to be 'some new text' // Object.is equality

I noticed that the CI tests failed after I submitted my pull request. However, the failure appears to be related to a test that is not associated with the changes I've made. I suspect it might be a flaky test. Could you please advise on how to proceed? Should I try rerunning the tests, or is there anything else you'd recommend?

capricorn86 commented 3 months ago
   FAIL  test/fetch/SyncFetch.test.ts > SyncFetch > send() > Updates cache after a failed revalidation with a "If-Modified-Since" request for a GET response with "Cache-Control" set to a "max-age".
  AssertionError: expected 'some text' to be 'some new text' // Object.is equality

I noticed that the CI tests failed after I submitted my pull request. However, the failure appears to be related to a test that is not associated with the changes I've made. I suspect it might be a flaky test. Could you please advise on how to proceed? Should I try rerunning the tests, or is there anything else you'd recommend?

It's a known problem that has to be fixed. It is related to a timing issue with the cache expire time for in Fetch.ts and SyncFetch.ts.