The ruling also ordered Hamas to release all hostages, and Hamas has previously claimed they would abide by any ruling of the court. I find it unlikely though that they will comply.
Hamas is not a state. ICJ is a tribunal that adjudicates disputes between states. ICJ has no jurisdiction to rule in regards to Hamas. Neither can Hamas bring a case against Israel, as it has no standing, considering it is not a party to the international treaty.