[code] Error raising scriptlets for testing
-
[ code ] Error raising scriptlets for testing purposes.
Here's a collection of scriptlets that
raiseerrors when you load them. They each only have one line of code:<span class="syntaxdefault">raise</span><span class="syntaxkeyword">(</span><span class="syntaxdefault">Exception</span><span class="syntaxkeyword">,</span><span class="syntaxstring">"This is a test error raised by '#{__FILE__}'"</span><span class="syntaxkeyword">)</span><span class="syntaxdefault"> </span>Load these scripts from one of your scripts or plugins, in order to test
what happens when exceptions are raised.Helps you refine your
rescueclauses, to trap all errors correctly. (I made them to test loading scripts from Ruby Console Plugins.)
I have them in a subfolder called Plugins/test/error so you'll see the zip folder is named "error", but you can put the error folder anywhere you wish (ex: a subfolder named "Plugins/dev".)
Each file is named after the exact Ruby
Exceptionclass, Ex: "SyntaxError.rb"
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better đ
Register LoginAdvertisement