How do you patch a method in Ruby as you do in Python via @patch decorator?
Whatever I've so far seen on Ruby's monkey patching falls into 'overloading' rather than patching. What I need now, is patch curb's curl method to return some expected results instead of actually looking up things. How do I do that? Import and overload curl.get()?
Is there even a same approach or should I start thinking somehow different?
Aucun commentaire:
Enregistrer un commentaire