()
| 161 | |
| 162 | // GJS: assertRaises(function) |
| 163 | function assertRaises() { |
| 164 | _validateArguments(1, arguments); |
| 165 | var fun=nonCommentArg(1, 1, arguments); |
| 166 | var exception; |
| 167 | |
| 168 | if (typeof(fun) != 'function') |
| 169 | error("Bad argument to assertRaises(function)"); |
| 170 | |
| 171 | var retval; |
| 172 | try { |
| 173 | retval = fun(); |
| 174 | } catch (e) { |
| 175 | exception = e; |
| 176 | } |
| 177 | |
| 178 | _assert(commentArg(1, arguments), exception !== top.JSUNIT_UNDEFINED_VALUE, "Call to assertRaises(function) did not raise an exception. Return value was " + _displayStringForValue(retval) + ' (' + typeof(retval) + ')'); |
| 179 | } |
| 180 | |
| 181 | function isLoaded() { |
| 182 | return isTestPageLoaded; |
nothing calls this directly
no test coverage detected