In reply to Rsignori92:
Sorry, but this is not legal. Some simulators are tolerating this others not.
My recommendation is to put in more `uvm_info calls to get more detailed information about the build_phase.
But I believe your problem is in the wait_for_test_done().