Without seeing what's behind the wall, there's no way to tell for sure, but unless there's another outlet to the sewer lower than what's shown, there's no way it could work...water doesn't go uphill. Yes, the WM has a pump, but you can't legally connect it directly into the sewer such that its pump could do it. You need a standpipe (could be one in the wall), a trap, and a vent - then, it can keep going to the sewer via gravity. In some places, it MIGHT still be legal to run a WM to its own drywell, but that's becoming a thing of the past.
Then, what is that copper pipe doing? Is that just an open T, and it's draining into there? Don't think that will meet any code, plus, you can't get a good seal so you'd have sewer gasses and if there was a backup, an opening for it to spew all over the basement.