Wed, 31 Dec 2014 13:27:57 +0100
Ignore runtime configuration files generated during quality assurance.
1 // Copyright 2009 the Sputnik authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
4 /**
5 * The production IterationStatement: "for (var VariableDeclarationNoIn in Expression) Statement"
6 *
7 * @path ch12/12.6/12.6.4/S12.6.4_A6.js
8 * @description Using Object with custom prototype as an Expression is appropriate. The prototype is "{feat:2,hint:"protohint"}"
9 */
11 function FACTORY(){this.prop=1;this.hint="hinted"};
13 FACTORY.prototype = {feat:2,hint:"protohint"};
15 var __instance = new FACTORY;
17 __accum="";
19 for (key in __instance){
20 __accum+=(key + __instance[key]);
21 }
23 //////////////////////////////////////////////////////////////////////////////
24 //CHECK#1
25 if (!((__accum.indexOf("prop1")!==-1)&&(__accum.indexOf("feat2")!==-1)&&(__accum.indexOf("hinthinted")!==-1))) {
26 $ERROR('#1: (__accum.indexOf("prop1")!==-1)&&(__accum.indexOf("feat2")!==-1)&&(__accum.indexOf("hinthinted")!==-1)');
27 }
28 //
29 //////////////////////////////////////////////////////////////////////////////
31 //////////////////////////////////////////////////////////////////////////////
32 //CHECK#2
33 if (__accum.indexOf("hintprotohint")!==-1) {
34 $ERROR('#2: __accum.indexOf("hintprotohint") === -1. Actual: __accum.indexOf("hintprotohint") ==='+ __accum.indexOf("hintprotohint") );
35 }
36 //
37 //////////////////////////////////////////////////////////////////////////////