o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1362090443.527427: @value"³9{I" class:EFI"BundledAsset;FI"logical_path;FI"expect/expect.js;TI" pathname;FI"2$root/app/assets/javascripts/expect/expect.js;FI"content_type;FI"application/javascript;FI" mtime;FI"2013-02-18T08:12:30+08:00;FI" length;Fi8I" digest;F"%afd573d7e350603ef0623ef3d5d2e52aI" source;FI"8(function(global,module){function expect(e){return new Assertion(e)}function Assertion(e,t,n){this.obj=e,this.flags={};if(undefined!=n){this.flags[t]=!0;for(var r in n.flags)n.flags.hasOwnProperty(r)&&(this.flags[r]=!0)}var i=t?flags[t]:keys(flags),s=this;if(i)for(var r=0,o=i.length;r-1&&(isArray(e)?a=map(a.split("\n"),function(e){return" "+e}).join("\n").substr(2):a="\n"+map(a.split("\n"),function(e){return" "+e}).join("\n"))):a=i("[Circular]","special"));if(typeof o=="undefined"){if(c==="Array"&&t.match(/^\d+$/))return a;o=json.stringify(""+t),o.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(o=o.substr(1,o.length-2),o=i(o,"name")):(o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=i(o,"string"))}return o+": "+a});r.pop();var v=0,m=reduce(d,function(e,t){return v++,indexOf(t,"\n")>=0&&v++,e+t.length+1},0);return m>50?d=h[0]+(l===""?"":l+"\n ")+" "+d.join(",\n ")+" "+h[1]:d=h[0]+l+" "+d.join(", ")+" "+h[1],d}var r=[];return s(e,typeof n=="undefined"?2:n)}function isArray(e){return Object.prototype.toString.call(e)=="[object Array]"}function isRegExp(e){var t;try{t=""+e}catch(n){return!1}return e instanceof RegExp||typeof e=="function"&&e.constructor.name==="RegExp"&&e.compile&&e.test&&e.exec&&t.match(/^\/.*\/[gim]{0,3}$/)}function isDate(e){return e instanceof Date?!0:!1}function keys(e){if(Object.keys)return Object.keys(e);var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return t}function map(e,t,n){if(Array.prototype.map)return Array.prototype.map.call(e,t,n);var r=new Array(e.length);for(var i=0,s=e.length;i=2)var i=arguments[1];else do{if(r in this){i=this[r++];break}if(++r>=n)throw new TypeError}while(!0);for(;r=0;s--)if(n[s]!=r[s])return!1;for(s=n.length-1;s>=0;s--){i=n[s];if(!expect.eql(e[i],t[i]))return!1}return!0}if("undefined"==typeof module)var module={exports:{}},exports=module.exports;module.exports=expect,expect.Assertion=Assertion,expect.version="0.1.2";var flags={not:["to","be","have","include","only"],to:["be","have","include","only","not"],only:["have"],have:["own"],be:["an"]};Assertion.prototype.assert=function(e,t,n){var t=this.flags.not?n:t,r=this.flags.not?!e:e;if(!r)throw new Error(t.call(this));this.and=new Assertion(this.obj)},Assertion.prototype.ok=function(){this.assert(!!this.obj,function(){return"expected "+i(this.obj)+" to be truthy"},function(){return"expected "+i(this.obj)+" to be falsy"})},Assertion.prototype.throwError=Assertion.prototype.throwException=function(e){expect(this.obj).to.be.a("function");var t=!1,n=this.flags.not;try{this.obj()}catch(r){if("function"==typeof e)e(r);else if("object"==typeof e){var i="string"==typeof r?r:r.message;n?expect(i).to.not.match(e):expect(i).to.match(e)}t=!0}"object"==typeof e&&n&&(this.flags.not=!1);var s=this.obj.name||"fn";this.assert(t,function(){return"expected "+s+" to throw an exception"},function(){return"expected "+s+" not to throw an exception"})},Assertion.prototype.empty=function(){var e;return"object"==typeof this.obj&&null!==this.obj&&!isArray(this.obj)?"number"==typeof this.obj.length?e=!this.obj.length:e=!keys(this.obj).length:("string"!=typeof this.obj&&expect(this.obj).to.be.an("object"),expect(this.obj).to.have.property("length"),e=!this.obj.length),this.assert(e,function(){return"expected "+i(this.obj)+" to be empty"},function(){return"expected "+i(this.obj)+" to not be empty"}),this},Assertion.prototype.be=Assertion.prototype.equal=function(e){return this.assert(e===this.obj,function(){return"expected "+i(this.obj)+" to equal "+i(e)},function(){return"expected "+i(this.obj)+" to not equal "+i(e)}),this},Assertion.prototype.eql=function(e){return this.assert(expect.eql(e,this.obj),function(){return"expected "+i(this.obj)+" to sort of equal "+i(e)},function(){return"expected "+i(this.obj)+" to sort of not equal "+i(e)}),this},Assertion.prototype.within=function(e,t){var n=e+".."+t;return this.assert(this.obj>=e&&this.obj<=t,function(){return"expected "+i(this.obj)+" to be within "+n},function(){return"expected "+i(this.obj)+" to not be within "+n}),this},Assertion.prototype.a=Assertion.prototype.an=function(e){if("string"==typeof e){var t=/^[aeiou]/.test(e)?"n":"";this.assert("array"==e?isArray(this.obj):"object"==e?"object"==typeof this.obj&&null!==this.obj:e==typeof this.obj,function(){return"expected "+i(this.obj)+" to be a"+t+" "+e},function(){return"expected "+i(this.obj)+" not to be a"+t+" "+e})}else{var n=e.name||"supplied constructor";this.assert(this.obj instanceof e,function(){return"expected "+i(this.obj)+" to be an instance of "+n},function(){return"expected "+i(this.obj)+" not to be an instance of "+n})}return this},Assertion.prototype.greaterThan=Assertion.prototype.above=function(e){return this.assert(this.obj>e,function(){return"expected "+i(this.obj)+" to be above "+e},function(){return"expected "+i(this.obj)+" to be below "+e}),this},Assertion.prototype.lessThan=Assertion.prototype.below=function(e){return this.assert(this.obj1){e=map(e,function(e){return i(e)});var o=e.pop();t=e.join(", ")+", and "+o}else t=i(e[0]);return t=(s>1?"keys ":"key ")+t,t=(this.flags.only?"only have ":"include ")+t,this.assert(n,function(){return"expected "+i(this.obj)+" to "+t},function(){return"expected "+i(this.obj)+" to not "+t}),this},Assertion.prototype.fail=function(e){return e=e||"explicit failure",this.assert(!1,e,e),this};var getOuterHTML=function(e){if("outerHTML"in e)return e.outerHTML;var t="http://www.w3.org/1999/xhtml",n=document.createElementNS(t,"_"),r=(window.HTMLElement||window.Element).prototype,i=new XMLSerializer,s;return document.xmlVersion?i.serializeToString(e):(n.appendChild(e.cloneNode(!1)),s=n.innerHTML.replace("><",">"+e.innerHTML+"<"),n.innerHTML="",s)},isDOMElement=function(e){return typeof HTMLElement=="object"?e instanceof HTMLElement:e&&typeof e=="object"&&e.nodeType===1&&typeof e.nodeName=="string"};expect.eql=function(t,n){if(t===n)return!0;if("undefined"!=typeof Buffer&&Buffer.isBuffer(t)&&Buffer.isBuffer(n)){if(t.length!=n.length)return!1;for(var r=0;r