esm: improve fetch_module test coverage and remove hack
#41947
Merged
8000
fetch_module test coverage and remove hack
#41947