> Hamas has previously claimed they would abide by any ruling of the court
No, Hamas previously claimed that they would observe a ceasefire if the court imposed one on Israel, conditioned on Israeli compliance with the same. They didn't say they would do anything related to anything other than an ceasefire order.
Unlikely that they will release the hostages just because a court said so.