PR#61772 added the ability to detect modern or legacy syntax for module.run
to allow both styles to co-exist. Those changes did not fully address
module.wait semantics which led to all module.wait syntaxes to be
treated as legacy. Using modern syntax led to state failure in such cases.
This commit adds additional keys that may be generated when module.wait is
used to the list of kwargs ignored by detection algorithm. It also adds
functional tests for module.wait test cases.
Fixes#62988