Install ember-cli-memory-leak-detector
This install ember-cli-memory-leak-detector
Congrats! No memory leaks were detected in this add-on (based on the coverage of the existing test suite)
PS This PR came out of the EmberConf contributor's workshop
Looks like ember-canary is causing the PageTitleService to leak, I'm unsure what changed in canary to cause this. Open to ideas!
Maybe the deprecation warning we see in the logs gives a hint here. I'll try see what exactly is deprecated.
I kicked CI for rerun to be sure it is not a one off issue.
Looks like a consistent issue, and in beta too.
It seems leak is coming from test setup only. In one test we create inline class for testing "titleDidUpdate" hook and that test leaks in beta and canary the mock class. (https://github.com/ember-cli/ember-page-title/blob/master/tests/acceptance/posts-test.js#L102)
Check out this diff - https://github.com/steveszc/ember-page-title/compare/ember-cli-memory-leak-detector...raido:ember-cli-memory-detector
By explicitly unregistering service:page-title leak disappears, I verified by checking heap retained objects as well.
Green CI run for 🔝 change - https://github.com/raido/ember-page-title/runs/2252988038
But not sure why in beta and canary this type of test setup introduces a leak in first place, maybe @rwjblue has any ideas?
Good sleuthing @raido
@rwjblue any ideas?