function useJasmineJquery(){jasmine.getFixtures=function(){return jasmine.currentFixtures_=jasmine.currentFixtures_||new jasmine.Fixtures},jasmine.Fixtures=function(){this.containerId="jasmine-fixtures",this.fixturesCache_={},this.fixturesPath="spec/javascripts/fixtures"},jasmine.Fixtures.prototype.set=function(e){this.cleanUp(),this.createContainer_(e)},jasmine.Fixtures.prototype.preload=function(){this.read.apply(this,arguments)},jasmine.Fixtures.prototype.load=function(){this.cleanUp(),this.createContainer_(this.read.apply(this,arguments))},jasmine.Fixtures.prototype.read=function(){for(var e=[],t=arguments,i=t.length,n=0;i>n;n++)e.push(this.getFixtureHtml_(t[n]));return e.join("")},jasmine.Fixtures.prototype.clearCache=function(){this.fixturesCache_={}},jasmine.Fixtures.prototype.cleanUp=function(){jQuery("#"+this.containerId).remove()},jasmine.Fixtures.prototype.sandbox=function(e){var t=e||{};return jQuery('
').attr(t)},jasmine.Fixtures.prototype.createContainer_=function(e){var t;e instanceof jQuery?(t=jQuery(''),t.html(e)):t=''+e+"
",jQuery("body").append(t)},jasmine.Fixtures.prototype.getFixtureHtml_=function(e){return this.fixturesCache_[e]===void 0&&this.loadFixtureIntoCache_(e),this.fixturesCache_[e]},jasmine.Fixtures.prototype.loadFixtureIntoCache_=function(e){var t=this,i=this.fixturesPath.match("/$")?this.fixturesPath+e:this.fixturesPath+"/"+e;jQuery.ajax({async:!1,cache:!1,dataType:"html",url:i,success:function(i){t.fixturesCache_[e]=i},error:function(e,t,n){throw Error("Fixture could not be loaded: "+i+" (status: "+t+", message: "+n.message+")")}})},jasmine.Fixtures.prototype.proxyCallTo_=function(e,t){return this[e].apply(this,t)},jasmine.JQuery=function(){},jasmine.JQuery.browserTagCaseIndependentHtml=function(e){return jQuery("").append(e).html()},jasmine.JQuery.elementToString=function(e){return jQuery("").append(e.clone()).html()},jasmine.JQuery.matchersClass={},function(e){var t={spiedEvents:{},handlers:[]};e.events={spyOn:function(e,i){var n=function(n){t.spiedEvents[[e,i]]=n};jQuery(e).bind(i,n),t.handlers.push(n)},wasTriggered:function(e,i){return!!t.spiedEvents[[e,i]]},cleanUp:function(){t.spiedEvents={},t.handlers=[]}}}(jasmine.JQuery),function(){var e={toHaveClass:function(e){return this.actual.hasClass(e)},toBeVisible:function(){return this.actual.is(":visible")},toBeHidden:function(){return this.actual.is(":hidden")},toBeSelected:function(){return this.actual.is(":selected")},toBeChecked:function(){return this.actual.is(":checked")},toBeEmpty:function(){return this.actual.is(":empty")},toExist:function(){return this.actual.size()>0},toHaveAttr:function(e,i){return t(this.actual.attr(e),i)},toHaveId:function(e){return this.actual.attr("id")==e},toHaveCSS:function(e,t){return e&&this.actual.css(e)===t?!0:!1},toHaveHtml:function(e){return this.actual.html()==jasmine.JQuery.browserTagCaseIndependentHtml(e)},toHaveText:function(e){return e&&jQuery.isFunction(e.test)?e.test(this.actual.text()):this.actual.text()==e},toHaveValue:function(e){return this.actual.val()==e},toHaveData:function(e,i){return t(this.actual.data(e),i)},toBe:function(e){return this.actual.is(e)},toContain:function(e){return this.actual.find(e).size()>0},toBeDisabled:function(){return this.actual.is(":disabled")},toHandle:function(e){var t=this.actual.data("events");return t&&t[e].length>0},toHandleWith:function(e,t){var i,n=this.actual.data("events")[e];for(i=0;n.length>i;i++)if(n[i].handler==t)return!0;return!1}},t=function(e,t){return void 0===t?void 0!==e:e==t},i=function(t){var i=jasmine.Matchers.prototype[t];jasmine.JQuery.matchersClass[t]=function(){if(this.actual instanceof jQuery){var n=e[t].apply(this,arguments);return this.actual=jasmine.JQuery.elementToString(this.actual),n}return i?i.apply(this,arguments):!1}};for(var n in e)i(n)}(),beforeEach(function(){this.addMatchers(jasmine.JQuery.matchersClass),this.addMatchers({toHaveBeenTriggeredOn:function(e){return this.message=function(){return["Expected event "+this.actual+" to have been triggered on"+e,"Expected event "+this.actual+" not to have been triggered on"+e]},jasmine.JQuery.events.wasTriggered(e,this.actual)}})}),afterEach(function(){jasmine.getFixtures().cleanUp(),jasmine.JQuery.events.cleanUp()})}(function(){function e(){(function(e){var t=document.createElement("style");t.type="text/css",t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e)),document.getElementsByTagName("body")[0].appendChild(t)})('body{background-color:#eee;padding:0;margin:5px;overflow-y:scroll}#HTMLReporter{font-size:11px;font-family:Monaco,"Lucida Console",monospace;line-height:14px;color:#333}#HTMLReporter a{text-decoration:none}#HTMLReporter a:hover{text-decoration:underline}#HTMLReporter p,#HTMLReporter h1,#HTMLReporter h2,#HTMLReporter h3,#HTMLReporter h4,#HTMLReporter h5,#HTMLReporter h6{margin:0;line-height:14px}#HTMLReporter .banner,#HTMLReporter .symbolSummary,#HTMLReporter .summary,#HTMLReporter .resultMessage,#HTMLReporter .specDetail .description,#HTMLReporter .alert .bar,#HTMLReporter .stackTrace{padding-left:9px;padding-right:9px}#HTMLReporter #jasmine_content{position:fixed;right:100%}#HTMLReporter .version{color:#aaa}#HTMLReporter .banner{margin-top:14px}#HTMLReporter .duration{color:#aaa;float:right}#HTMLReporter .symbolSummary{overflow:hidden;*zoom:1;margin:14px 0}#HTMLReporter .symbolSummary li{display:block;float:left;height:7px;width:14px;margin-bottom:7px;font-size:16px}#HTMLReporter .symbolSummary li.passed{font-size:14px}#HTMLReporter .symbolSummary li.passed:before{color:#5e7d00;content:"\\02022"}#HTMLReporter .symbolSummary li.failed{line-height:9px}#HTMLReporter .symbolSummary li.failed:before{color:#b03911;content:"x";font-weight:bold;margin-left:-1px}#HTMLReporter .symbolSummary li.skipped{font-size:14px}#HTMLReporter .symbolSummary li.skipped:before{color:#bababa;content:"\\02022"}#HTMLReporter .symbolSummary li.pending{line-height:11px}#HTMLReporter .symbolSummary li.pending:before{color:#aaa;content:"-"}#HTMLReporter .exceptions{color:#fff;float:right;margin-top:5px;margin-right:5px}#HTMLReporter .bar{line-height:28px;font-size:14px;display:block;color:#eee}#HTMLReporter .runningAlert{background-color:#666}#HTMLReporter .skippedAlert{background-color:#aaa}#HTMLReporter .skippedAlert:first-child{background-color:#333}#HTMLReporter .skippedAlert:hover{text-decoration:none;color:white;text-decoration:underline}#HTMLReporter .passingAlert{background-color:#a6b779}#HTMLReporter .passingAlert:first-child{background-color:#5e7d00}#HTMLReporter .failingAlert{background-color:#cf867e}#HTMLReporter .failingAlert:first-child{background-color:#b03911}#HTMLReporter .results{margin-top:14px}#HTMLReporter #details{display:none}#HTMLReporter .resultsMenu,#HTMLReporter .resultsMenu a{background-color:#fff;color:#333}#HTMLReporter.showDetails .summaryMenuItem{font-weight:normal;text-decoration:inherit}#HTMLReporter.showDetails .summaryMenuItem:hover{text-decoration:underline}#HTMLReporter.showDetails .detailsMenuItem{font-weight:bold;text-decoration:underline}#HTMLReporter.showDetails .summary{display:none}#HTMLReporter.showDetails #details{display:block}#HTMLReporter .summaryMenuItem{font-weight:bold;text-decoration:underline}#HTMLReporter .summary{margin-top:14px}#HTMLReporter .summary .suite .suite,#HTMLReporter .summary .specSummary{margin-left:14px}#HTMLReporter .summary .specSummary.passed a{color:#5e7d00}#HTMLReporter .summary .specSummary.failed a{color:#b03911}#HTMLReporter .description+.suite{margin-top:0}#HTMLReporter .suite{margin-top:14px}#HTMLReporter .suite a{color:#333}#HTMLReporter #details .specDetail{margin-bottom:28px}#HTMLReporter #details .specDetail .description{display:block;color:white;background-color:#b03911}#HTMLReporter .resultMessage{padding-top:14px;color:#333}#HTMLReporter .resultMessage span.result{display:block}#HTMLReporter .stackTrace{margin:5px 0 0 0;max-height:224px;overflow:auto;line-height:18px;color:#666;border:1px solid #ddd;background:white;white-space:pre}#TrivialReporter{padding:8px 13px;position:absolute;top:0;bottom:0;left:0;right:0;overflow-y:scroll;background-color:white;font-family:"Helvetica Neue Light","Lucida Grande","Calibri","Arial",sans-serif}#TrivialReporter a:visited,#TrivialReporter a{color:#303}#TrivialReporter a:hover,#TrivialReporter a:active{color:blue}#TrivialReporter .run_spec{float:right;padding-right:5px;font-size:.8em;text-decoration:none}#TrivialReporter .banner{color:#303;background-color:#fef;padding:5px}#TrivialReporter .logo{float:left;font-size:1.1em;padding-left:5px}#TrivialReporter .logo .version{font-size:.6em;padding-left:1em}#TrivialReporter .runner.running{background-color:yellow}#TrivialReporter .options{text-align:right;font-size:.8em}#TrivialReporter .suite{border:1px outset gray;margin:5px 0;padding-left:1em}#TrivialReporter .suite .suite{margin:5px}#TrivialReporter .suite.passed{background-color:#dfd}#TrivialReporter .suite.failed{background-color:#fdd}#TrivialReporter .spec{margin:5px;padding-left:1em;clear:both}#TrivialReporter .spec.failed,#TrivialReporter .spec.passed,#TrivialReporter .spec.skipped{padding-bottom:5px;border:1px solid gray}#TrivialReporter .spec.failed{background-color:#fbb;border-color:red}#TrivialReporter .spec.passed{background-color:#bfb;border-color:green}#TrivialReporter .spec.skipped{background-color:#bbb}#TrivialReporter .messages{border-left:1px dashed gray;padding-left:1em;padding-right:1em}#TrivialReporter .passed{background-color:#cfc;display:none}#TrivialReporter .failed{background-color:#fbb}#TrivialReporter .skipped{color:#777;background-color:#eee;display:none}#TrivialReporter .resultMessage span.result{display:block;line-height:2em;color:black}#TrivialReporter .resultMessage .mismatch{color:black}#TrivialReporter .stackTrace{white-space:pre;font-size:.8em;margin-left:10px;max-height:5em;overflow:auto;border:1px inset red;padding:1em;background:#eef}#TrivialReporter .finished-at{padding-left:1em;font-size:.6em}#TrivialReporter.show-passed .passed,#TrivialReporter.show-skipped .skipped{display:block}#TrivialReporter #jasmine_content{position:fixed;right:100%}#TrivialReporter .runner{border:1px solid gray;display:block;margin:5px 0;padding:2px 0 2px 10px}'),s&&setTimeout(n,1)}function t(){s=!1}function i(e){r={body:e,location:document.location}}function n(){var e=jasmine.getEnv();e.updateInterval=1e3,null!=window.jQuery&&useJasmineJquery();var t=new jasmine.HtmlReporter(r);e.addReporter(t),e.specFilter=function(e){return t.specFilter(e)},e.execute()}var s=!0,r=document;window.jasmineRunner={init:e,noAutoRun:t,attachTo:i,run:n},document.addEventListener?document.addEventListener("DOMContentLoaded",e,!1):document.attachEvent("DOMContentLoaded",e)})("1.3.1-build-3");var isCommonJS="undefined"==typeof window&&"object"==typeof exports,jasmine={};isCommonJS&&(exports.jasmine=jasmine),jasmine.unimplementedMethod_=function(){throw Error("unimplemented method")},jasmine.undefined=jasmine.___undefined___,jasmine.VERBOSE=!1,jasmine.DEFAULT_UPDATE_INTERVAL=250,jasmine.MAX_PRETTY_PRINT_DEPTH=40,jasmine.DEFAULT_TIMEOUT_INTERVAL=5e3,jasmine.CATCH_EXCEPTIONS=!0,jasmine.getGlobal=function(){function e(){return this}return e()},jasmine.bindOriginal_=function(e,t){var i=e[t];return i.apply?function(){return i.apply(e,arguments)}:jasmine.getGlobal()[t]},jasmine.setTimeout=jasmine.bindOriginal_(jasmine.getGlobal(),"setTimeout"),jasmine.clearTimeout=jasmine.bindOriginal_(jasmine.getGlobal(),"clearTimeout"),jasmine.setInterval=jasmine.bindOriginal_(jasmine.getGlobal(),"setInterval"),jasmine.clearInterval=jasmine.bindOriginal_(jasmine.getGlobal(),"clearInterval"),jasmine.MessageResult=function(e){this.type="log",this.values=e,this.trace=Error()},jasmine.MessageResult.prototype.toString=function(){for(var e="",t=0;this.values.length>t;t++)t>0&&(e+=" "),e+=jasmine.isString_(this.values[t])?this.values[t]:jasmine.pp(this.values[t]);return e},jasmine.ExpectationResult=function(e){this.type="expect",this.matcherName=e.matcherName,this.passed_=e.passed,this.expected=e.expected,this.actual=e.actual,this.message=this.passed_?"Passed.":e.message;var t=e.trace||Error(this.message);this.trace=this.passed_?"":t},jasmine.ExpectationResult.prototype.toString=function(){return this.message},jasmine.ExpectationResult.prototype.passed=function(){return this.passed_},jasmine.getEnv=function(){var e=jasmine.currentEnv_=jasmine.currentEnv_||new jasmine.Env;return e},jasmine.isArray_=function(e){return jasmine.isA_("Array",e)},jasmine.isString_=function(e){return jasmine.isA_("String",e)},jasmine.isNumber_=function(e){return jasmine.isA_("Number",e)},jasmine.isA_=function(e,t){return Object.prototype.toString.apply(t)==="[object "+e+"]"},jasmine.pp=function(e){var t=new jasmine.StringPrettyPrinter;return t.format(e),t.string},jasmine.isDomNode=function(e){return e.nodeType>0},jasmine.any=function(e){return new jasmine.Matchers.Any(e)},jasmine.objectContaining=function(e){return new jasmine.Matchers.ObjectContaining(e)},jasmine.Spy=function(e){this.identity=e||"unknown",this.isSpy=!0,this.plan=function(){},this.mostRecentCall={},this.argsForCall=[],this.calls=[]},jasmine.Spy.prototype.andCallThrough=function(){return this.plan=this.originalValue,this},jasmine.Spy.prototype.andReturn=function(e){return this.plan=function(){return e},this},jasmine.Spy.prototype.andThrow=function(e){return this.plan=function(){throw e},this},jasmine.Spy.prototype.andCallFake=function(e){return this.plan=e,this},jasmine.Spy.prototype.reset=function(){this.wasCalled=!1,this.callCount=0,this.argsForCall=[],this.calls=[],this.mostRecentCall={}},jasmine.createSpy=function(e){var t=function(){t.wasCalled=!0,t.callCount++;var e=jasmine.util.argsToArray(arguments);return t.mostRecentCall.object=this,t.mostRecentCall.args=e,t.argsForCall.push(e),t.calls.push({object:this,args:e}),t.plan.apply(this,arguments)},i=new jasmine.Spy(e);for(var n in i)t[n]=i[n];return t.reset(),t},jasmine.isSpy=function(e){return e&&e.isSpy},jasmine.createSpyObj=function(e,t){if(!jasmine.isArray_(t)||0===t.length)throw Error("createSpyObj requires a non-empty array of method names to create spies for");for(var i={},n=0;t.length>n;n++)i[t[n]]=jasmine.createSpy(e+"."+t[n]);return i},jasmine.log=function(){var e=jasmine.getEnv().currentSpec;e.log.apply(e,arguments)};var spyOn=function(e,t){return jasmine.getEnv().currentSpec.spyOn(e,t)};isCommonJS&&(exports.spyOn=spyOn);var it=function(e,t){return jasmine.getEnv().it(e,t)};isCommonJS&&(exports.it=it);var xit=function(e,t){return jasmine.getEnv().xit(e,t)};isCommonJS&&(exports.xit=xit);var expect=function(e){return jasmine.getEnv().currentSpec.expect(e)};isCommonJS&&(exports.expect=expect);var runs=function(e){jasmine.getEnv().currentSpec.runs(e)};isCommonJS&&(exports.runs=runs);var waits=function(e){jasmine.getEnv().currentSpec.waits(e)};isCommonJS&&(exports.waits=waits);var waitsFor=function(){jasmine.getEnv().currentSpec.waitsFor.apply(jasmine.getEnv().currentSpec,arguments)};isCommonJS&&(exports.waitsFor=waitsFor);var beforeEach=function(e){jasmine.getEnv().beforeEach(e)};isCommonJS&&(exports.beforeEach=beforeEach);var afterEach=function(e){jasmine.getEnv().afterEach(e)};isCommonJS&&(exports.afterEach=afterEach);var describe=function(e,t){return jasmine.getEnv().describe(e,t)};isCommonJS&&(exports.describe=describe);var xdescribe=function(e,t){return jasmine.getEnv().xdescribe(e,t)};isCommonJS&&(exports.xdescribe=xdescribe),jasmine.XmlHttpRequest="undefined"==typeof XMLHttpRequest?function(){function e(e){try{return e()}catch(t){}return null}var t=e(function(){return new ActiveXObject("Msxml2.XMLHTTP.6.0")})||e(function(){return new ActiveXObject("Msxml2.XMLHTTP.3.0")})||e(function(){return new ActiveXObject("Msxml2.XMLHTTP")})||e(function(){return new ActiveXObject("Microsoft.XMLHTTP")});if(!t)throw Error("This browser does not support XMLHttpRequest.");return t}:XMLHttpRequest,jasmine.util={},jasmine.util.inherit=function(e,t){var i=function(){};i.prototype=t.prototype,e.prototype=new i},jasmine.util.formatException=function(e){var t;e.line?t=e.line:e.lineNumber&&(t=e.lineNumber);var i;e.sourceURL?i=e.sourceURL:e.fileName&&(i=e.fileName);var n=e.name&&e.message?e.name+": "+e.message:""+e;return i&&t&&(n+=" in "+i+" (line "+t+")"),n},jasmine.util.htmlEscape=function(e){return e?e.replace(/&/g,"&").replace(//g,">"):e},jasmine.util.argsToArray=function(e){for(var t=[],i=0;e.length>i;i++)t.push(e[i]);return t},jasmine.util.extend=function(e,t){for(var i in t)e[i]=t[i];return e},jasmine.Env=function(){this.currentSpec=null,this.currentSuite=null,this.currentRunner_=new jasmine.Runner(this),this.reporter=new jasmine.MultiReporter,this.updateInterval=jasmine.DEFAULT_UPDATE_INTERVAL,this.defaultTimeoutInterval=jasmine.DEFAULT_TIMEOUT_INTERVAL,this.lastUpdate=0,this.specFilter=function(){return!0},this.nextSpecId_=0,this.nextSuiteId_=0,this.equalityTesters_=[],this.matchersClass=function(){jasmine.Matchers.apply(this,arguments)},jasmine.util.inherit(this.matchersClass,jasmine.Matchers),jasmine.Matchers.wrapInto_(jasmine.Matchers.prototype,this.matchersClass)},jasmine.Env.prototype.setTimeout=jasmine.setTimeout,jasmine.Env.prototype.clearTimeout=jasmine.clearTimeout,jasmine.Env.prototype.setInterval=jasmine.setInterval,jasmine.Env.prototype.clearInterval=jasmine.clearInterval,jasmine.Env.prototype.version=function(){if(jasmine.version_)return jasmine.version_;throw Error("Version not set")},jasmine.Env.prototype.versionString=function(){if(!jasmine.version_)return"version unknown";var e=this.version(),t=e.major+"."+e.minor+"."+e.build;return e.release_candidate&&(t+=".rc"+e.release_candidate),t+=" revision "+e.revision},jasmine.Env.prototype.nextSpecId=function(){return this.nextSpecId_++},jasmine.Env.prototype.nextSuiteId=function(){return this.nextSuiteId_++},jasmine.Env.prototype.addReporter=function(e){this.reporter.addReporter(e)},jasmine.Env.prototype.execute=function(){this.currentRunner_.execute()},jasmine.Env.prototype.describe=function(e,t){var i=new jasmine.Suite(this,e,t,this.currentSuite),n=this.currentSuite;n?n.add(i):this.currentRunner_.add(i),this.currentSuite=i;var s=null;try{t.call(i)}catch(r){s=r}return s&&this.it("encountered a declaration exception",function(){throw s}),this.currentSuite=n,i},jasmine.Env.prototype.beforeEach=function(e){this.currentSuite?this.currentSuite.beforeEach(e):this.currentRunner_.beforeEach(e)},jasmine.Env.prototype.currentRunner=function(){return this.currentRunner_},jasmine.Env.prototype.afterEach=function(e){this.currentSuite?this.currentSuite.afterEach(e):this.currentRunner_.afterEach(e)},jasmine.Env.prototype.xdescribe=function(){return{execute:function(){}}},jasmine.Env.prototype.it=function(e,t){var i=new jasmine.Spec(this,this.currentSuite,e);return this.currentSuite.add(i),this.currentSpec=i,t&&i.runs(t),i},jasmine.Env.prototype.xit=function(){return{id:this.nextSpecId(),runs:function(){}}},jasmine.Env.prototype.compareRegExps_=function(e,t,i,n){return e.source!=t.source&&n.push("expected pattern /"+t.source+"/ is not equal to the pattern /"+e.source+"/"),e.ignoreCase!=t.ignoreCase&&n.push("expected modifier i was"+(t.ignoreCase?" ":" not ")+"set and does not equal the origin modifier"),e.global!=t.global&&n.push("expected modifier g was"+(t.global?" ":" not ")+"set and does not equal the origin modifier"),e.multiline!=t.multiline&&n.push("expected modifier m was"+(t.multiline?" ":" not ")+"set and does not equal the origin modifier"),e.sticky!=t.sticky&&n.push("expected modifier y was"+(t.sticky?" ":" not ")+"set and does not equal the origin modifier"),0===n.length},jasmine.Env.prototype.compareObjects_=function(e,t,i,n){if(e.__Jasmine_been_here_before__===t&&t.__Jasmine_been_here_before__===e)return!0;e.__Jasmine_been_here_before__=t,t.__Jasmine_been_here_before__=e;var s=function(e,t){return null!==e&&e[t]!==jasmine.undefined};for(var r in t)!s(e,r)&&s(t,r)&&i.push("expected has key '"+r+"', but missing from actual.");for(r in e)!s(t,r)&&s(e,r)&&i.push("expected missing key '"+r+"', but present in actual.");for(r in t)"__Jasmine_been_here_before__"!=r&&(this.equals_(e[r],t[r],i,n)||n.push("'"+r+"' was '"+(t[r]?jasmine.util.htmlEscape(""+t[r]):t[r])+"' in expected, but was '"+(e[r]?jasmine.util.htmlEscape(""+e[r]):e[r])+"' in actual."));return jasmine.isArray_(e)&&jasmine.isArray_(t)&&e.length!=t.length&&n.push("arrays were not the same length"),delete e.__Jasmine_been_here_before__,delete t.__Jasmine_been_here_before__,0===i.length&&0===n.length},jasmine.Env.prototype.equals_=function(e,t,i,n){i=i||[],n=n||[];for(var s=0;this.equalityTesters_.length>s;s++){var r=this.equalityTesters_[s],a=r(e,t,this,i,n);if(a!==jasmine.undefined)return a}return e===t?!0:e===jasmine.undefined||null===e||t===jasmine.undefined||null===t?e==jasmine.undefined&&t==jasmine.undefined:jasmine.isDomNode(e)&&jasmine.isDomNode(t)?e===t:e instanceof Date&&t instanceof Date?e.getTime()==t.getTime():e.jasmineMatches?e.jasmineMatches(t):t.jasmineMatches?t.jasmineMatches(e):e instanceof jasmine.Matchers.ObjectContaining?e.matches(t):t instanceof jasmine.Matchers.ObjectContaining?t.matches(e):jasmine.isString_(e)&&jasmine.isString_(t)?e==t:jasmine.isNumber_(e)&&jasmine.isNumber_(t)?e==t:e instanceof RegExp&&t instanceof RegExp?this.compareRegExps_(e,t,i,n):"object"==typeof e&&"object"==typeof t?this.compareObjects_(e,t,i,n):e===t},jasmine.Env.prototype.contains_=function(e,t){if(jasmine.isArray_(e)){for(var i=0;e.length>i;i++)if(this.equals_(e[i],t))return!0;return!1}return e.indexOf(t)>=0},jasmine.Env.prototype.addEqualityTester=function(e){this.equalityTesters_.push(e)},jasmine.Reporter=function(){},jasmine.Reporter.prototype.reportRunnerStarting=function(){},jasmine.Reporter.prototype.reportRunnerResults=function(){},jasmine.Reporter.prototype.reportSuiteResults=function(){},jasmine.Reporter.prototype.reportSpecStarting=function(){},jasmine.Reporter.prototype.reportSpecResults=function(){},jasmine.Reporter.prototype.log=function(){},jasmine.Block=function(e,t,i){this.env=e,this.func=t,this.spec=i},jasmine.Block.prototype.execute=function(e){if(jasmine.CATCH_EXCEPTIONS)try{this.func.apply(this.spec)}catch(t){this.spec.fail(t)}else this.func.apply(this.spec);e()},jasmine.JsApiReporter=function(){this.started=!1,this.finished=!1,this.suites_=[],this.results_={}},jasmine.JsApiReporter.prototype.reportRunnerStarting=function(e){this.started=!0;for(var t=e.topLevelSuites(),i=0;t.length>i;i++){var n=t[i];this.suites_.push(this.summarize_(n))}},jasmine.JsApiReporter.prototype.suites=function(){return this.suites_},jasmine.JsApiReporter.prototype.summarize_=function(e){var t=e instanceof jasmine.Suite,i={id:e.id,name:e.description,type:t?"suite":"spec",children:[]};if(t)for(var n=e.children(),s=0;n.length>s;s++)i.children.push(this.summarize_(n[s]));return i},jasmine.JsApiReporter.prototype.results=function(){return this.results_},jasmine.JsApiReporter.prototype.resultsForSpec=function(e){return this.results_[e]},jasmine.JsApiReporter.prototype.reportRunnerResults=function(){this.finished=!0},jasmine.JsApiReporter.prototype.reportSuiteResults=function(){},jasmine.JsApiReporter.prototype.reportSpecResults=function(e){this.results_[e.id]={messages:e.results().getItems(),result:e.results().failedCount>0?"failed":"passed"}},jasmine.JsApiReporter.prototype.log=function(){},jasmine.JsApiReporter.prototype.resultsForSpecs=function(e){for(var t={},i=0;e.length>i;i++){var n=e[i];t[n]=this.summarizeResult_(this.results_[n])}return t},jasmine.JsApiReporter.prototype.summarizeResult_=function(e){for(var t=[],i=e.messages.length,n=0;i>n;n++){var s=e.messages[n];t.push({text:"log"==s.type?""+s:jasmine.undefined,passed:s.passed?s.passed():!0,type:s.type,message:s.message,trace:{stack:s.passed&&!s.passed()?s.trace.stack:jasmine.undefined}})}return{result:e.result,messages:t}},jasmine.Matchers=function(e,t,i,n){this.env=e,this.actual=t,this.spec=i,this.isNot=n||!1,this.reportWasCalled_=!1},jasmine.Matchers.pp=function(){throw Error("jasmine.Matchers.pp() is no longer supported, please use jasmine.pp() instead!")},jasmine.Matchers.prototype.report=function(){throw Error("As of jasmine 0.11, custom matchers must be implemented differently -- please see jasmine docs")},jasmine.Matchers.wrapInto_=function(e,t){for(var i in e)if("report"!=i){var n=e[i];t.prototype[i]=jasmine.Matchers.matcherFn_(i,n)}},jasmine.Matchers.matcherFn_=function(e,t){return function(){var i=jasmine.util.argsToArray(arguments),n=t.apply(this,arguments);if(this.isNot&&(n=!n),this.reportWasCalled_)return n;var s;if(!n)if(this.message)s=this.message.apply(this,arguments),jasmine.isArray_(s)&&(s=s[this.isNot?1:0]);else{var r=e.replace(/[A-Z]/g,function(e){return" "+e.toLowerCase()});if(s="Expected "+jasmine.pp(this.actual)+(this.isNot?" not ":" ")+r,i.length>0)for(var a=0;i.length>a;a++)a>0&&(s+=","),s+=" "+jasmine.pp(i[a]);s+="."}var o=new jasmine.ExpectationResult({matcherName:e,passed:n,expected:i.length>1?i:i[0],actual:this.actual,message:s});return this.spec.addMatcherResult(o),jasmine.undefined}},jasmine.Matchers.prototype.toBe=function(e){return this.actual===e},jasmine.Matchers.prototype.toNotBe=function(e){return this.actual!==e},jasmine.Matchers.prototype.toEqual=function(e){return this.env.equals_(this.actual,e)},jasmine.Matchers.prototype.toNotEqual=function(e){return!this.env.equals_(this.actual,e)},jasmine.Matchers.prototype.toMatch=function(e){return RegExp(e).test(this.actual)},jasmine.Matchers.prototype.toNotMatch=function(e){return!RegExp(e).test(this.actual)},jasmine.Matchers.prototype.toBeDefined=function(){return this.actual!==jasmine.undefined},jasmine.Matchers.prototype.toBeUndefined=function(){return this.actual===jasmine.undefined},jasmine.Matchers.prototype.toBeNull=function(){return null===this.actual},jasmine.Matchers.prototype.toBeNaN=function(){return this.message=function(){return["Expected "+jasmine.pp(this.actual)+" to be NaN."]},this.actual!==this.actual},jasmine.Matchers.prototype.toBeTruthy=function(){return!!this.actual},jasmine.Matchers.prototype.toBeFalsy=function(){return!this.actual},jasmine.Matchers.prototype.toHaveBeenCalled=function(){if(arguments.length>0)throw Error("toHaveBeenCalled does not take arguments, use toHaveBeenCalledWith");if(!jasmine.isSpy(this.actual))throw Error("Expected a spy, but got "+jasmine.pp(this.actual)+".");return this.message=function(){return["Expected spy "+this.actual.identity+" to have been called.","Expected spy "+this.actual.identity+" not to have been called."]},this.actual.wasCalled},jasmine.Matchers.prototype.wasCalled=jasmine.Matchers.prototype.toHaveBeenCalled,jasmine.Matchers.prototype.wasNotCalled=function(){if(arguments.length>0)throw Error("wasNotCalled does not take arguments");if(!jasmine.isSpy(this.actual))throw Error("Expected a spy, but got "+jasmine.pp(this.actual)+".");return this.message=function(){return["Expected spy "+this.actual.identity+" to not have been called.","Expected spy "+this.actual.identity+" to have been called."]},!this.actual.wasCalled},jasmine.Matchers.prototype.toHaveBeenCalledWith=function(){var e=jasmine.util.argsToArray(arguments);if(!jasmine.isSpy(this.actual))throw Error("Expected a spy, but got "+jasmine.pp(this.actual)+".");return this.message=function(){var t="Expected spy "+this.actual.identity+" not to have been called with "+jasmine.pp(e)+" but it was.",i="";return i=0===this.actual.callCount?"Expected spy "+this.actual.identity+" to have been called with "+jasmine.pp(e)+" but it was never called.":"Expected spy "+this.actual.identity+" to have been called with "+jasmine.pp(e)+" but actual calls were "+jasmine.pp(this.actual.argsForCall).replace(/^\[ | \]$/g,""),[i,t]},this.env.contains_(this.actual.argsForCall,e)},jasmine.Matchers.prototype.wasCalledWith=jasmine.Matchers.prototype.toHaveBeenCalledWith,jasmine.Matchers.prototype.wasNotCalledWith=function(){var e=jasmine.util.argsToArray(arguments);if(!jasmine.isSpy(this.actual))throw Error("Expected a spy, but got "+jasmine.pp(this.actual)+".");return this.message=function(){return["Expected spy not to have been called with "+jasmine.pp(e)+" but it was","Expected spy to have been called with "+jasmine.pp(e)+" but it was"]},!this.env.contains_(this.actual.argsForCall,e)},jasmine.Matchers.prototype.toContain=function(e){return this.env.contains_(this.actual,e)},jasmine.Matchers.prototype.toNotContain=function(e){return!this.env.contains_(this.actual,e)},jasmine.Matchers.prototype.toBeLessThan=function(e){return e>this.actual},jasmine.Matchers.prototype.toBeGreaterThan=function(e){return this.actual>e},jasmine.Matchers.prototype.toBeCloseTo=function(e,t){return 0!==t&&(t=t||2),Math.pow(10,-t)/2>Math.abs(e-this.actual)},jasmine.Matchers.prototype.toThrow=function(e){var t,i=!1;if("function"!=typeof this.actual)throw Error("Actual is not a function");try{this.actual()}catch(n){t=n}t&&(i=e===jasmine.undefined||this.env.equals_(t.message||t,e.message||e));var s=this.isNot?"not ":"";return this.message=function(){return!t||e!==jasmine.undefined&&this.env.equals_(t.message||t,e.message||e)?"Expected function to throw an exception.":["Expected function "+s+"to throw",e?e.message||e:"an exception",", but it threw",t.message||t].join(" ")},i},jasmine.Matchers.Any=function(e){this.expectedClass=e},jasmine.Matchers.Any.prototype.jasmineMatches=function(e){return this.expectedClass==String?"string"==typeof e||e instanceof String:this.expectedClass==Number?"number"==typeof e||e instanceof Number:this.expectedClass==Function?"function"==typeof e||e instanceof Function:this.expectedClass==Object?"object"==typeof e:e instanceof this.expectedClass},jasmine.Matchers.Any.prototype.jasmineToString=function(){return""},jasmine.Matchers.ObjectContaining=function(e){this.sample=e},jasmine.Matchers.ObjectContaining.prototype.jasmineMatches=function(e,t,i){t=t||[],i=i||[];var n=jasmine.getEnv(),s=function(e,t){return null!=e&&e[t]!==jasmine.undefined};for(var r in this.sample)!s(e,r)&&s(this.sample,r)?t.push("expected has key '"+r+"', but missing from actual."):n.equals_(this.sample[r],e[r],t,i)||i.push("'"+r+"' was '"+(e[r]?jasmine.util.htmlEscape(""+e[r]):e[r])+"' in expected, but was '"+(this.sample[r]?jasmine.util.htmlEscape(""+this.sample[r]):this.sample[r])+"' in actual.");return 0===t.length&&0===i.length},jasmine.Matchers.ObjectContaining.prototype.jasmineToString=function(){return""},jasmine.FakeTimer=function(){this.reset();var e=this;e.setTimeout=function(t,i){return e.timeoutsMade++,e.scheduleFunction(e.timeoutsMade,t,i,!1),e.timeoutsMade},e.setInterval=function(t,i){return e.timeoutsMade++,e.scheduleFunction(e.timeoutsMade,t,i,!0),e.timeoutsMade},e.clearTimeout=function(t){e.scheduledFunctions[t]=jasmine.undefined},e.clearInterval=function(t){e.scheduledFunctions[t]=jasmine.undefined}},jasmine.FakeTimer.prototype.reset=function(){this.timeoutsMade=0,this.scheduledFunctions={},this.nowMillis=0},jasmine.FakeTimer.prototype.tick=function(e){var t=this.nowMillis,i=t+e;this.runFunctionsWithinRange(t,i),this.nowMillis=i},jasmine.FakeTimer.prototype.runFunctionsWithinRange=function(e,t){var i,n=[];for(var s in this.scheduledFunctions)i=this.scheduledFunctions[s],i!=jasmine.undefined&&i.runAtMillis>=e&&t>=i.runAtMillis&&(n.push(i),this.scheduledFunctions[s]=jasmine.undefined);if(n.length>0){n.sort(function(e,t){return e.runAtMillis-t.runAtMillis});for(var r=0;n.length>r;++r)try{var a=n[r];this.nowMillis=a.runAtMillis,a.funcToCall(),a.recurring&&this.scheduleFunction(a.timeoutKey,a.funcToCall,a.millis,!0)}catch(o){}this.runFunctionsWithinRange(e,t)}},jasmine.FakeTimer.prototype.scheduleFunction=function(e,t,i,n){this.scheduledFunctions[e]={runAtMillis:this.nowMillis+i,funcToCall:t,recurring:n,timeoutKey:e,millis:i}
},jasmine.Clock={defaultFakeTimer:new jasmine.FakeTimer,reset:function(){jasmine.Clock.assertInstalled(),jasmine.Clock.defaultFakeTimer.reset()},tick:function(e){jasmine.Clock.assertInstalled(),jasmine.Clock.defaultFakeTimer.tick(e)},runFunctionsWithinRange:function(e,t){jasmine.Clock.defaultFakeTimer.runFunctionsWithinRange(e,t)},scheduleFunction:function(e,t,i,n){jasmine.Clock.defaultFakeTimer.scheduleFunction(e,t,i,n)},useMock:function(){if(!jasmine.Clock.isInstalled()){var e=jasmine.getEnv().currentSpec;e.after(jasmine.Clock.uninstallMock),jasmine.Clock.installMock()}},installMock:function(){jasmine.Clock.installed=jasmine.Clock.defaultFakeTimer},uninstallMock:function(){jasmine.Clock.assertInstalled(),jasmine.Clock.installed=jasmine.Clock.real},real:{setTimeout:jasmine.getGlobal().setTimeout,clearTimeout:jasmine.getGlobal().clearTimeout,setInterval:jasmine.getGlobal().setInterval,clearInterval:jasmine.getGlobal().clearInterval},assertInstalled:function(){if(!jasmine.Clock.isInstalled())throw Error("Mock clock is not installed, use jasmine.Clock.useMock()")},isInstalled:function(){return jasmine.Clock.installed==jasmine.Clock.defaultFakeTimer},installed:null},jasmine.Clock.installed=jasmine.Clock.real,jasmine.getGlobal().setTimeout=function(e,t){return jasmine.Clock.installed.setTimeout.apply?jasmine.Clock.installed.setTimeout.apply(this,arguments):jasmine.Clock.installed.setTimeout(e,t)},jasmine.getGlobal().setInterval=function(e,t){return jasmine.Clock.installed.setInterval.apply?jasmine.Clock.installed.setInterval.apply(this,arguments):jasmine.Clock.installed.setInterval(e,t)},jasmine.getGlobal().clearTimeout=function(e){return jasmine.Clock.installed.clearTimeout.apply?jasmine.Clock.installed.clearTimeout.apply(this,arguments):jasmine.Clock.installed.clearTimeout(e)},jasmine.getGlobal().clearInterval=function(e){return jasmine.Clock.installed.clearTimeout.apply?jasmine.Clock.installed.clearInterval.apply(this,arguments):jasmine.Clock.installed.clearInterval(e)},jasmine.MultiReporter=function(){this.subReporters_=[]},jasmine.util.inherit(jasmine.MultiReporter,jasmine.Reporter),jasmine.MultiReporter.prototype.addReporter=function(e){this.subReporters_.push(e)},function(){for(var e=["reportRunnerStarting","reportRunnerResults","reportSuiteResults","reportSpecStarting","reportSpecResults","log"],t=0;e.length>t;t++){var i=e[t];jasmine.MultiReporter.prototype[i]=function(e){return function(){for(var t=0;this.subReporters_.length>t;t++){var i=this.subReporters_[t];i[e]&&i[e].apply(i,arguments)}}}(i)}}(),jasmine.NestedResults=function(){this.totalCount=0,this.passedCount=0,this.failedCount=0,this.skipped=!1,this.items_=[]},jasmine.NestedResults.prototype.rollupCounts=function(e){this.totalCount+=e.totalCount,this.passedCount+=e.passedCount,this.failedCount+=e.failedCount},jasmine.NestedResults.prototype.log=function(e){this.items_.push(new jasmine.MessageResult(e))},jasmine.NestedResults.prototype.getItems=function(){return this.items_},jasmine.NestedResults.prototype.addResult=function(e){"log"!=e.type&&(e.items_?this.rollupCounts(e):(this.totalCount++,e.passed()?this.passedCount++:this.failedCount++)),this.items_.push(e)},jasmine.NestedResults.prototype.passed=function(){return this.passedCount===this.totalCount},jasmine.PrettyPrinter=function(){this.ppNestLevel_=0},jasmine.PrettyPrinter.prototype.format=function(e){this.ppNestLevel_++;try{e===jasmine.undefined?this.emitScalar("undefined"):null===e?this.emitScalar("null"):e===jasmine.getGlobal()?this.emitScalar(""):e.jasmineToString?this.emitScalar(e.jasmineToString()):"string"==typeof e?this.emitString(e):jasmine.isSpy(e)?this.emitScalar("spy on "+e.identity):e instanceof RegExp?this.emitScalar(""+e):"function"==typeof e?this.emitScalar("Function"):"number"==typeof e.nodeType?this.emitScalar("HTMLNode"):e instanceof Date?this.emitScalar("Date("+e+")"):e.__Jasmine_been_here_before__?this.emitScalar(""):jasmine.isArray_(e)||"object"==typeof e?(e.__Jasmine_been_here_before__=!0,jasmine.isArray_(e)?this.emitArray(e):this.emitObject(e),delete e.__Jasmine_been_here_before__):this.emitScalar(""+e)}finally{this.ppNestLevel_--}},jasmine.PrettyPrinter.prototype.iterateObject=function(e,t){for(var i in e)e.hasOwnProperty(i)&&"__Jasmine_been_here_before__"!=i&&t(i,e.__lookupGetter__?e.__lookupGetter__(i)!==jasmine.undefined&&null!==e.__lookupGetter__(i):!1)},jasmine.PrettyPrinter.prototype.emitArray=jasmine.unimplementedMethod_,jasmine.PrettyPrinter.prototype.emitObject=jasmine.unimplementedMethod_,jasmine.PrettyPrinter.prototype.emitScalar=jasmine.unimplementedMethod_,jasmine.PrettyPrinter.prototype.emitString=jasmine.unimplementedMethod_,jasmine.StringPrettyPrinter=function(){jasmine.PrettyPrinter.call(this),this.string=""},jasmine.util.inherit(jasmine.StringPrettyPrinter,jasmine.PrettyPrinter),jasmine.StringPrettyPrinter.prototype.emitScalar=function(e){this.append(e)},jasmine.StringPrettyPrinter.prototype.emitString=function(e){this.append("'"+e+"'")},jasmine.StringPrettyPrinter.prototype.emitArray=function(e){if(this.ppNestLevel_>jasmine.MAX_PRETTY_PRINT_DEPTH)return this.append("Array"),void 0;this.append("[ ");for(var t=0;e.length>t;t++)t>0&&this.append(", "),this.format(e[t]);this.append(" ]")},jasmine.StringPrettyPrinter.prototype.emitObject=function(e){if(this.ppNestLevel_>jasmine.MAX_PRETTY_PRINT_DEPTH)return this.append("Object"),void 0;var t=this;this.append("{ ");var i=!0;this.iterateObject(e,function(n,s){i?i=!1:t.append(", "),t.append(n),t.append(" : "),s?t.append(""):t.format(e[n])}),this.append(" }")},jasmine.StringPrettyPrinter.prototype.append=function(e){this.string+=e},jasmine.Queue=function(e){this.env=e,this.ensured=[],this.blocks=[],this.running=!1,this.index=0,this.offset=0,this.abort=!1},jasmine.Queue.prototype.addBefore=function(e,t){t===jasmine.undefined&&(t=!1),this.blocks.unshift(e),this.ensured.unshift(t)},jasmine.Queue.prototype.add=function(e,t){t===jasmine.undefined&&(t=!1),this.blocks.push(e),this.ensured.push(t)},jasmine.Queue.prototype.insertNext=function(e,t){t===jasmine.undefined&&(t=!1),this.ensured.splice(this.index+this.offset+1,0,t),this.blocks.splice(this.index+this.offset+1,0,e),this.offset++},jasmine.Queue.prototype.start=function(e){this.running=!0,this.onComplete=e,this.next_()},jasmine.Queue.prototype.isRunning=function(){return this.running},jasmine.Queue.LOOP_DONT_RECURSE=!0,jasmine.Queue.prototype.next_=function(){for(var e=this,t=!0;t;)if(t=!1,e.blocks.length>e.index&&(!this.abort||this.ensured[e.index])){var i=!0,n=!1,s=function(){if(jasmine.Queue.LOOP_DONT_RECURSE&&i)return n=!0,void 0;e.blocks[e.index].abort&&(e.abort=!0),e.offset=0,e.index++;var s=(new Date).getTime();e.env.updateInterval&&s-e.env.lastUpdate>e.env.updateInterval?(e.env.lastUpdate=s,e.env.setTimeout(function(){e.next_()},0)):jasmine.Queue.LOOP_DONT_RECURSE&&n?t=!0:e.next_()};e.blocks[e.index].execute(s),i=!1,n&&s()}else e.running=!1,e.onComplete&&e.onComplete()},jasmine.Queue.prototype.results=function(){for(var e=new jasmine.NestedResults,t=0;this.blocks.length>t;t++)this.blocks[t].results&&e.addResult(this.blocks[t].results());return e},jasmine.Runner=function(e){var t=this;t.env=e,t.queue=new jasmine.Queue(e),t.before_=[],t.after_=[],t.suites_=[]},jasmine.Runner.prototype.execute=function(){var e=this;e.env.reporter.reportRunnerStarting&&e.env.reporter.reportRunnerStarting(this),e.queue.start(function(){e.finishCallback()})},jasmine.Runner.prototype.beforeEach=function(e){e.typeName="beforeEach",this.before_.splice(0,0,e)},jasmine.Runner.prototype.afterEach=function(e){e.typeName="afterEach",this.after_.splice(0,0,e)},jasmine.Runner.prototype.finishCallback=function(){this.env.reporter.reportRunnerResults(this)},jasmine.Runner.prototype.addSuite=function(e){this.suites_.push(e)},jasmine.Runner.prototype.add=function(e){e instanceof jasmine.Suite&&this.addSuite(e),this.queue.add(e)},jasmine.Runner.prototype.specs=function(){for(var e=this.suites(),t=[],i=0;e.length>i;i++)t=t.concat(e[i].specs());return t},jasmine.Runner.prototype.suites=function(){return this.suites_},jasmine.Runner.prototype.topLevelSuites=function(){for(var e=[],t=0;this.suites_.length>t;t++)this.suites_[t].parentSuite||e.push(this.suites_[t]);return e},jasmine.Runner.prototype.results=function(){return this.queue.results()},jasmine.Spec=function(e,t,i){if(!e)throw Error("jasmine.Env() required");if(!t)throw Error("jasmine.Suite() required");var n=this;n.id=e.nextSpecId?e.nextSpecId():null,n.env=e,n.suite=t,n.description=i,n.queue=new jasmine.Queue(e),n.afterCallbacks=[],n.spies_=[],n.results_=new jasmine.NestedResults,n.results_.description=i,n.matchersClass=null},jasmine.Spec.prototype.getFullName=function(){return this.suite.getFullName()+" "+this.description+"."},jasmine.Spec.prototype.results=function(){return this.results_},jasmine.Spec.prototype.log=function(){return this.results_.log(arguments)},jasmine.Spec.prototype.runs=function(e){var t=new jasmine.Block(this.env,e,this);return this.addToQueue(t),this},jasmine.Spec.prototype.addToQueue=function(e){this.queue.isRunning()?this.queue.insertNext(e):this.queue.add(e)},jasmine.Spec.prototype.addMatcherResult=function(e){this.results_.addResult(e)},jasmine.Spec.prototype.expect=function(e){var t=new(this.getMatchersClass_())(this.env,e,this);return t.not=new(this.getMatchersClass_())(this.env,e,this,!0),t},jasmine.Spec.prototype.waits=function(e){var t=new jasmine.WaitsBlock(this.env,e,this);return this.addToQueue(t),this},jasmine.Spec.prototype.waitsFor=function(){for(var e=null,t=null,i=null,n=0;arguments.length>n;n++){var s=arguments[n];switch(typeof s){case"function":e=s;break;case"string":t=s;break;case"number":i=s}}var r=new jasmine.WaitsForBlock(this.env,i,e,t,this);return this.addToQueue(r),this},jasmine.Spec.prototype.fail=function(e){var t=new jasmine.ExpectationResult({passed:!1,message:e?jasmine.util.formatException(e):"Exception",trace:{stack:e.stack}});this.results_.addResult(t)},jasmine.Spec.prototype.getMatchersClass_=function(){return this.matchersClass||this.env.matchersClass},jasmine.Spec.prototype.addMatchers=function(e){var t=this.getMatchersClass_(),i=function(){t.apply(this,arguments)};jasmine.util.inherit(i,t),jasmine.Matchers.wrapInto_(e,i),this.matchersClass=i},jasmine.Spec.prototype.finishCallback=function(){this.env.reporter.reportSpecResults(this)},jasmine.Spec.prototype.finish=function(e){this.removeAllSpies(),this.finishCallback(),e&&e()},jasmine.Spec.prototype.after=function(e){this.queue.isRunning()?this.queue.add(new jasmine.Block(this.env,e,this),!0):this.afterCallbacks.unshift(e)},jasmine.Spec.prototype.execute=function(e){var t=this;return t.env.specFilter(t)?(this.env.reporter.reportSpecStarting(this),t.env.currentSpec=t,t.addBeforesAndAftersToQueue(),t.queue.start(function(){t.finish(e)}),void 0):(t.results_.skipped=!0,t.finish(e),void 0)},jasmine.Spec.prototype.addBeforesAndAftersToQueue=function(){for(var e,t=this.env.currentRunner(),i=this.suite;i;i=i.parentSuite)for(e=0;i.before_.length>e;e++)this.queue.addBefore(new jasmine.Block(this.env,i.before_[e],this));for(e=0;t.before_.length>e;e++)this.queue.addBefore(new jasmine.Block(this.env,t.before_[e],this));for(e=0;this.afterCallbacks.length>e;e++)this.queue.add(new jasmine.Block(this.env,this.afterCallbacks[e],this),!0);for(i=this.suite;i;i=i.parentSuite)for(e=0;i.after_.length>e;e++)this.queue.add(new jasmine.Block(this.env,i.after_[e],this),!0);for(e=0;t.after_.length>e;e++)this.queue.add(new jasmine.Block(this.env,t.after_[e],this),!0)},jasmine.Spec.prototype.explodes=function(){throw"explodes function should not have been called"},jasmine.Spec.prototype.spyOn=function(e,t,i){if(e==jasmine.undefined)throw"spyOn could not find an object to spy upon for "+t+"()";if(!i&&e[t]===jasmine.undefined)throw t+"() method does not exist";if(!i&&e[t]&&e[t].isSpy)throw Error(t+" has already been spied upon");var n=jasmine.createSpy(t);return this.spies_.push(n),n.baseObj=e,n.methodName=t,n.originalValue=e[t],e[t]=n,n},jasmine.Spec.prototype.removeAllSpies=function(){for(var e=0;this.spies_.length>e;e++){var t=this.spies_[e];t.baseObj[t.methodName]=t.originalValue}this.spies_=[]},jasmine.Suite=function(e,t,i,n){var s=this;s.id=e.nextSuiteId?e.nextSuiteId():null,s.description=t,s.queue=new jasmine.Queue(e),s.parentSuite=n,s.env=e,s.before_=[],s.after_=[],s.children_=[],s.suites_=[],s.specs_=[]},jasmine.Suite.prototype.getFullName=function(){for(var e=this.description,t=this.parentSuite;t;t=t.parentSuite)e=t.description+" "+e;return e},jasmine.Suite.prototype.finish=function(e){this.env.reporter.reportSuiteResults(this),this.finished=!0,"function"==typeof e&&e()},jasmine.Suite.prototype.beforeEach=function(e){e.typeName="beforeEach",this.before_.unshift(e)},jasmine.Suite.prototype.afterEach=function(e){e.typeName="afterEach",this.after_.unshift(e)},jasmine.Suite.prototype.results=function(){return this.queue.results()},jasmine.Suite.prototype.add=function(e){this.children_.push(e),e instanceof jasmine.Suite?(this.suites_.push(e),this.env.currentRunner().addSuite(e)):this.specs_.push(e),this.queue.add(e)},jasmine.Suite.prototype.specs=function(){return this.specs_},jasmine.Suite.prototype.suites=function(){return this.suites_},jasmine.Suite.prototype.children=function(){return this.children_},jasmine.Suite.prototype.execute=function(e){var t=this;this.queue.start(function(){t.finish(e)})},jasmine.WaitsBlock=function(e,t,i){this.timeout=t,jasmine.Block.call(this,e,null,i)},jasmine.util.inherit(jasmine.WaitsBlock,jasmine.Block),jasmine.WaitsBlock.prototype.execute=function(e){jasmine.VERBOSE&&this.env.reporter.log(">> Jasmine waiting for "+this.timeout+" ms..."),this.env.setTimeout(function(){e()},this.timeout)},jasmine.WaitsForBlock=function(e,t,i,n,s){this.timeout=t||e.defaultTimeoutInterval,this.latchFunction=i,this.message=n,this.totalTimeSpentWaitingForLatch=0,jasmine.Block.call(this,e,null,s)},jasmine.util.inherit(jasmine.WaitsForBlock,jasmine.Block),jasmine.WaitsForBlock.TIMEOUT_INCREMENT=10,jasmine.WaitsForBlock.prototype.execute=function(e){jasmine.VERBOSE&&this.env.reporter.log(">> Jasmine waiting for "+(this.message||"something to happen"));var t;try{t=this.latchFunction.apply(this.spec)}catch(i){return this.spec.fail(i),e(),void 0}if(t)e();else if(this.totalTimeSpentWaitingForLatch>=this.timeout){var n="timed out after "+this.timeout+" msec waiting for "+(this.message||"something to happen");this.spec.fail({name:"timeout",message:n}),this.abort=!0,e()}else{this.totalTimeSpentWaitingForLatch+=jasmine.WaitsForBlock.TIMEOUT_INCREMENT;var s=this;this.env.setTimeout(function(){s.execute(e)},jasmine.WaitsForBlock.TIMEOUT_INCREMENT)}},jasmine.version_={major:1,minor:3,build:1,revision:1354556913},jasmine.HtmlReporterHelpers={},jasmine.HtmlReporterHelpers.createDom=function(e,t){for(var i=document.createElement(e),n=2;arguments.length>n;n++){var s=arguments[n];"string"==typeof s?i.appendChild(document.createTextNode(s)):s&&i.appendChild(s)}for(var r in t)"className"==r?i[r]=t[r]:i.setAttribute(r,t[r]);return i},jasmine.HtmlReporterHelpers.getSpecStatus=function(e){var t=e.results(),i=t.passed()?"passed":"failed";return t.skipped&&(i="skipped"),i},jasmine.HtmlReporterHelpers.appendToSummary=function(e,t){var i=this.dom.summary,n=e.parentSuite===void 0?"suite":"parentSuite",s=e[n];s&&(this.views.suites[s.id]===void 0&&(this.views.suites[s.id]=new jasmine.HtmlReporter.SuiteView(s,this.dom,this.views)),i=this.views.suites[s.id].element),i.appendChild(t)},jasmine.HtmlReporterHelpers.addHelpers=function(e){for(var t in jasmine.HtmlReporterHelpers)e.prototype[t]=jasmine.HtmlReporterHelpers[t]},jasmine.HtmlReporter=function(e){function t(){var e;return function(){if(!e){for(var t=[],i=jasmine.HtmlReporter.parameters(u),n=0;i.length>n;n++){var s=i[n].split("=");t[decodeURIComponent(s[0])]=decodeURIComponent(s[1])}e=t.spec}}(),e}function i(e){p.reporter=o.createDom("div",{id:"HTMLReporter",className:"jasmine_reporter"},p.banner=o.createDom("div",{className:"banner"},o.createDom("span",{className:"title"},"Jasmine "),o.createDom("span",{className:"version"},e)),p.symbolSummary=o.createDom("ul",{className:"symbolSummary"}),p.alert=o.createDom("div",{className:"alert"},o.createDom("span",{className:"exceptions"},o.createDom("label",{className:"label","for":"no_try_catch"},"No try/catch"),o.createDom("input",{id:"no_try_catch",type:"checkbox"}))),p.results=o.createDom("div",{className:"results"},p.summary=o.createDom("div",{className:"summary"}),p.details=o.createDom("div",{id:"details"})))}function n(){return window.location.search.match(/catch=false/)}function s(){for(var e=jasmine.HtmlReporter.parameters(window.document),t=!1,i=0;!t&&e.length>i;)e[i].match(/catch=/)&&(e.splice(i,1),t=!0),i++;return jasmine.CATCH_EXCEPTIONS&&e.push("catch=false"),e.join("&")}function r(){var e=document.getElementById("no_try_catch");n()&&(e.setAttribute("checked",!0),jasmine.CATCH_EXCEPTIONS=!1),e.onclick=function(){window.location.search=s()}}var a,o=this,u=e||window.document,p={};return o.logRunningSpecs=!1,o.reportRunnerStarting=function(e){var t=e.specs()||[];0!=t.length&&(i(e.env.versionString()),u.body.appendChild(p.reporter),r(),a=new jasmine.HtmlReporter.ReporterView(p),a.addSpecs(t,o.specFilter))},o.reportRunnerResults=function(){a&&a.complete()},o.reportSuiteResults=function(e){a.suiteComplete(e)},o.reportSpecStarting=function(e){o.logRunningSpecs&&o.log(">> Jasmine Running "+e.suite.description+" "+e.description+"...")},o.reportSpecResults=function(e){a.specComplete(e)},o.log=function(){var e=jasmine.getGlobal().console;e&&e.log&&(e.log.apply?e.log.apply(e,arguments):e.log(arguments))},o.specFilter=function(e){return t()?0===e.getFullName().indexOf(t()):!0},o},jasmine.HtmlReporter.parameters=function(e){var t=e.location.search.substring(1),i=[];return t.length>0&&(i=t.split("&")),i},jasmine.HtmlReporter.sectionLink=function(e){var t="?",i=[];return e&&i.push("spec="+encodeURIComponent(e)),jasmine.CATCH_EXCEPTIONS||i.push("catch=false"),i.length>0&&(t+=i.join("&")),t},jasmine.HtmlReporterHelpers.addHelpers(jasmine.HtmlReporter),jasmine.HtmlReporter.ReporterView=function(e){function t(){-1===e.reporter.className.search(/showDetails/)&&(e.reporter.className+=" showDetails")}function i(e){return e===void 0}function n(e){return!i(e)}function s(e){var t=e+" spec";return e>1&&(t+="s"),t}return this.startedAt=new Date,this.runningSpecCount=0,this.completeSpecCount=0,this.passedCount=0,this.failedCount=0,this.skippedCount=0,this.createResultsMenu=function(){this.resultsMenu=this.createDom("span",{className:"resultsMenu bar"},this.summaryMenuItem=this.createDom("a",{className:"summaryMenuItem",href:"#"},"0 specs")," | ",this.detailsMenuItem=this.createDom("a",{className:"detailsMenuItem",href:"#"},"0 failing")),this.summaryMenuItem.onclick=function(){e.reporter.className=e.reporter.className.replace(/ showDetails/g,"")},this.detailsMenuItem.onclick=function(){t()}},this.addSpecs=function(t,i){this.totalSpecCount=t.length,this.views={specs:{},suites:{}};for(var n=0;t.length>n;n++){var s=t[n];this.views.specs[s.id]=new jasmine.HtmlReporter.SpecView(s,e,this.views),i(s)&&this.runningSpecCount++}},this.specComplete=function(t){this.completeSpecCount++,i(this.views.specs[t.id])&&(this.views.specs[t.id]=new jasmine.HtmlReporter.SpecView(t,e));var n=this.views.specs[t.id];switch(n.status()){case"passed":this.passedCount++;break;case"failed":this.failedCount++;break;case"skipped":this.skippedCount++}n.refresh(),this.refresh()},this.suiteComplete=function(e){var t=this.views.suites[e.id];i(t)||t.refresh()},this.refresh=function(){i(this.resultsMenu)&&this.createResultsMenu(),i(this.runningAlert)&&(this.runningAlert=this.createDom("a",{href:jasmine.HtmlReporter.sectionLink(),className:"runningAlert bar"}),e.alert.appendChild(this.runningAlert)),this.runningAlert.innerHTML="Running "+this.completeSpecCount+" of "+s(this.totalSpecCount),i(this.skippedAlert)&&(this.skippedAlert=this.createDom("a",{href:jasmine.HtmlReporter.sectionLink(),className:"skippedAlert bar"})),this.skippedAlert.innerHTML="Skipping "+this.skippedCount+" of "+s(this.totalSpecCount)+" - run all",1===this.skippedCount&&n(e.alert)&&e.alert.appendChild(this.skippedAlert),i(this.passedAlert)&&(this.passedAlert=this.createDom("span",{href:jasmine.HtmlReporter.sectionLink(),className:"passingAlert bar"})),this.passedAlert.innerHTML="Passing "+s(this.passedCount),i(this.failedAlert)&&(this.failedAlert=this.createDom("span",{href:"?",className:"failingAlert bar"})),this.failedAlert.innerHTML="Failing "+s(this.failedCount),1===this.failedCount&&n(e.alert)&&(e.alert.appendChild(this.failedAlert),e.alert.appendChild(this.resultsMenu)),this.summaryMenuItem.innerHTML=""+s(this.runningSpecCount),this.detailsMenuItem.innerHTML=""+this.failedCount+" failing"},this.complete=function(){e.alert.removeChild(this.runningAlert),this.skippedAlert.innerHTML="Ran "+this.runningSpecCount+" of "+s(this.totalSpecCount)+" - run all",0===this.failedCount?e.alert.appendChild(this.createDom("span",{className:"passingAlert bar"},"Passing "+s(this.passedCount))):t(),e.banner.appendChild(this.createDom("span",{className:"duration"},"finished in "+((new Date).getTime()-this.startedAt.getTime())/1e3+"s"))},this},jasmine.HtmlReporterHelpers.addHelpers(jasmine.HtmlReporter.ReporterView),jasmine.HtmlReporter.SpecView=function(e,t,i){this.spec=e,this.dom=t,this.views=i,this.symbol=this.createDom("li",{className:"pending"}),this.dom.symbolSummary.appendChild(this.symbol),this.summary=this.createDom("div",{className:"specSummary"},this.createDom("a",{className:"description",href:jasmine.HtmlReporter.sectionLink(this.spec.getFullName()),title:this.spec.getFullName()},this.spec.description)),this.detail=this.createDom("div",{className:"specDetail"},this.createDom("a",{className:"description",href:"?spec="+encodeURIComponent(this.spec.getFullName()),title:this.spec.getFullName()},this.spec.getFullName()))},jasmine.HtmlReporter.SpecView.prototype.status=function(){return this.getSpecStatus(this.spec)},jasmine.HtmlReporter.SpecView.prototype.refresh=function(){switch(this.symbol.className=this.status(),this.status()){case"skipped":break;case"passed":this.appendSummaryToSuiteDiv();break;case"failed":this.appendSummaryToSuiteDiv(),this.appendFailureDetail()}},jasmine.HtmlReporter.SpecView.prototype.appendSummaryToSuiteDiv=function(){this.summary.className+=" "+this.status(),this.appendToSummary(this.spec,this.summary)},jasmine.HtmlReporter.SpecView.prototype.appendFailureDetail=function(){this.detail.className+=" "+this.status();for(var e=this.spec.results().getItems(),t=this.createDom("div",{className:"messages"}),i=0;e.length>i;i++){var n=e[i];"log"==n.type?t.appendChild(this.createDom("div",{className:"resultMessage log"},""+n)):"expect"==n.type&&n.passed&&!n.passed()&&(t.appendChild(this.createDom("div",{className:"resultMessage fail"},n.message)),n.trace.stack&&t.appendChild(this.createDom("div",{className:"stackTrace"},n.trace.stack)))}t.childNodes.length>0&&(this.detail.appendChild(t),this.dom.details.appendChild(this.detail))},jasmine.HtmlReporterHelpers.addHelpers(jasmine.HtmlReporter.SpecView),jasmine.HtmlReporter.SuiteView=function(e,t,i){this.suite=e,this.dom=t,this.views=i,this.element=this.createDom("div",{className:"suite"},this.createDom("a",{className:"description",href:jasmine.HtmlReporter.sectionLink(this.suite.getFullName())},this.suite.description)),this.appendToSummary(this.suite,this.element)},jasmine.HtmlReporter.SuiteView.prototype.status=function(){return this.getSpecStatus(this.suite)},jasmine.HtmlReporter.SuiteView.prototype.refresh=function(){this.element.className+=" "+this.status()},jasmine.HtmlReporterHelpers.addHelpers(jasmine.HtmlReporter.SuiteView),jasmine.TrivialReporter=function(e){this.document=e||document,this.suiteDivs={},this.logRunningSpecs=!1},jasmine.TrivialReporter.prototype.createDom=function(e,t){for(var i=document.createElement(e),n=2;arguments.length>n;n++){var s=arguments[n];"string"==typeof s?i.appendChild(document.createTextNode(s)):s&&i.appendChild(s)}for(var r in t)"className"==r?i[r]=t[r]:i.setAttribute(r,t[r]);return i},jasmine.TrivialReporter.prototype.reportRunnerStarting=function(e){var t,i;this.outerDiv=this.createDom("div",{id:"TrivialReporter",className:"jasmine_reporter"},this.createDom("div",{className:"banner"},this.createDom("div",{className:"logo"},this.createDom("span",{className:"title"},"Jasmine"),this.createDom("span",{className:"version"},e.env.versionString())),this.createDom("div",{className:"options"},"Show ",t=this.createDom("input",{id:"__jasmine_TrivialReporter_showPassed__",type:"checkbox"}),this.createDom("label",{"for":"__jasmine_TrivialReporter_showPassed__"}," passed "),i=this.createDom("input",{id:"__jasmine_TrivialReporter_showSkipped__",type:"checkbox"}),this.createDom("label",{"for":"__jasmine_TrivialReporter_showSkipped__"}," skipped"))),this.runnerDiv=this.createDom("div",{className:"runner running"},this.createDom("a",{className:"run_spec",href:"?"},"run all"),this.runnerMessageSpan=this.createDom("span",{},"Running..."),this.finishedAtSpan=this.createDom("span",{className:"finished-at"},""))),this.document.body.appendChild(this.outerDiv);for(var n=e.suites(),s=0;n.length>s;s++){var r=n[s],a=this.createDom("div",{className:"suite"},this.createDom("a",{className:"run_spec",href:"?spec="+encodeURIComponent(r.getFullName())},"run"),this.createDom("a",{className:"description",href:"?spec="+encodeURIComponent(r.getFullName())},r.description));this.suiteDivs[r.id]=a;var o=this.outerDiv;r.parentSuite&&(o=this.suiteDivs[r.parentSuite.id]),o.appendChild(a)}this.startedAt=new Date;var u=this;t.onclick=function(){t.checked?u.outerDiv.className+=" show-passed":u.outerDiv.className=u.outerDiv.className.replace(/ show-passed/,"")},i.onclick=function(){i.checked?u.outerDiv.className+=" show-skipped":u.outerDiv.className=u.outerDiv.className.replace(/ show-skipped/,"")}},jasmine.TrivialReporter.prototype.reportRunnerResults=function(e){var t=e.results(),i=t.failedCount>0?"runner failed":"runner passed";this.runnerDiv.setAttribute("class",i),this.runnerDiv.setAttribute("className",i);for(var n=e.specs(),s=0,r=0;n.length>r;r++)this.specFilter(n[r])&&s++;var a=""+s+" spec"+(1==s?"":"s")+", "+t.failedCount+" failure"+(1==t.failedCount?"":"s");a+=" in "+((new Date).getTime()-this.startedAt.getTime())/1e3+"s",this.runnerMessageSpan.replaceChild(this.createDom("a",{className:"description",href:"?"},a),this.runnerMessageSpan.firstChild),this.finishedAtSpan.appendChild(document.createTextNode("Finished at "+(""+new Date)))},jasmine.TrivialReporter.prototype.reportSuiteResults=function(e){var t=e.results(),i=t.passed()?"passed":"failed";0===t.totalCount&&(i="skipped"),this.suiteDivs[e.id].className+=" "+i},jasmine.TrivialReporter.prototype.reportSpecStarting=function(e){this.logRunningSpecs&&this.log(">> Jasmine Running "+e.suite.description+" "+e.description+"...")},jasmine.TrivialReporter.prototype.reportSpecResults=function(e){var t=e.results(),i=t.passed()?"passed":"failed";t.skipped&&(i="skipped");for(var n=this.createDom("div",{className:"spec "+i},this.createDom("a",{className:"run_spec",href:"?spec="+encodeURIComponent(e.getFullName())},"run"),this.createDom("a",{className:"description",href:"?spec="+encodeURIComponent(e.getFullName()),title:e.getFullName()},e.description)),s=t.getItems(),r=this.createDom("div",{className:"messages"}),a=0;s.length>a;a++){var o=s[a];"log"==o.type?r.appendChild(this.createDom("div",{className:"resultMessage log"},""+o)):"expect"==o.type&&o.passed&&!o.passed()&&(r.appendChild(this.createDom("div",{className:"resultMessage fail"},o.message)),o.trace.stack&&r.appendChild(this.createDom("div",{className:"stackTrace"},o.trace.stack)))}r.childNodes.length>0&&n.appendChild(r),this.suiteDivs[e.suite.id].appendChild(n)},jasmine.TrivialReporter.prototype.log=function(){var e=jasmine.getGlobal().console;e&&e.log&&(e.log.apply?e.log.apply(e,arguments):e.log(arguments))},jasmine.TrivialReporter.prototype.getLocation=function(){return this.document.location},jasmine.TrivialReporter.prototype.specFilter=function(e){for(var t={},i=this.getLocation().search.substring(1).split("&"),n=0;i.length>n;n++){var s=i[n].split("=");t[decodeURIComponent(s[0])]=decodeURIComponent(s[1])}return t.spec?0===e.getFullName().indexOf(t.spec):!0};