-
-
Save marzdgzmn/b3d8ec6e60bc700a5fd1c8b58247ff8d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def sync | |
Database.update_sync_result(FAILED) | |
log_error reuslt.output | |
exit | |
end | |
allow(sync).to receive(:exit).and_throw(:exit) | |
expect(DB).to receive(:update_sync_result).with(SyncStatus::FAILED) | |
expect { sync.run }.to throw_symbol :exit | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment