We need the following info to give you a logical answer.
Model number, type #, code # of the removed engine.
Same info from the installed engine.
Name and Model number of the machine (tractor).
Hope you have not already burned out the ignition coils.
If it's cranking and no spark, you need to disconnect the black kill wire coming from the ignition coils and check for spark. Heads up if the engine starts with the wire disconnected you will need to GROUND this wire to kill the engine FAST. I would removed both spark plug wires to reduce a chance of it starting.
If it's a single cylinder engine you removed the engine wiring is different is why we need all the above requested info including the tractor model number so as to see the tractor kill/charge/ and start wiring.