Home | History | Annotate | Download | only in unittest
      1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 'use strict';
      6 
      7 base.exportTo('base.unittest', function() {
      8   function TestError(opt_message) {
      9     var that = new Error(opt_message);
     10     Error.captureStackTrace(that, TestError);
     11     that.__proto__ = TestError.prototype;
     12     return that;
     13   }
     14 
     15   TestError.prototype = {
     16     __proto__: Error.prototype
     17   };
     18 
     19   return {
     20     TestError: TestError
     21   };
     22 });
     23