Since water did flow to the icemaker when you switched the wires from the dispenser, it does indicate the water line is clear. Since the valve has been replaced, I recommend cycling the icemaker manually and checking the voltage at the water valve when the icemaker calls for water toward the end of the cycle. I'm attaching a picture with instructions to cycle the icemaker. Be very careful making this check and make sure the wires are still connected to the valve when making this check. There will be a voltage drop to the valve but it should still get approx. 100 volts to it. If this voltage is not there, the problem could be with the icemaker or the main board. This can be difficult making these voltage checks and I would recommend having a technician make these checks. Another check you can try will be to lower the icemaker and place a jumper between the black and red wires. Be sure to disconnect the power first. With the jumper in place, reconnect the power and if water now flows to the icemaker, the icemaker will need to be replaced. If no water flows, since the water valve has been replaced, it would lead to a defective board but to determine for sure, the board will need to be checked. I would recommend having a technician make this check. If you would like more assistance, I will be glad to assist you further.