The warning that is printing is trying to lead you down the right path. mstest
is obsolete. You need to switch to the vstest runner instead. Adjust your command line to use the newer tool. I suspect your problem will go away.
As for mstest it can generate this error in a variety of cases so there is potentially a pathing problem. If it doesn't find all the binaries it expects it can generate the error. This includes the test adapter and test framework assemblies. Given that you're running Jenkins I'd probably start by verifying the test path it is trying to run against. Another cause is misconfigured or missing toolset so I'd make sure you installed CodedUI as well. CodedUI is deprecated so it is possible that something is missing from the VS2022 release that Jenkins needs.