summaryrefslogtreecommitdiff
path: root/external/contributions/Google/sputnik_conformance_modified/08_Types/8.4_The_String_Type/S8.4_A10.js
blob: 34d1407d4b7e41a99569b03db5e302bef64d7971 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Copyright 2009 the Sputnik authors.  All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.

/**
* @name: S8.4_A10;
* @section: 8.4, 7.8.4;
* @assertion: Both unicode and ascii chars are allowed;
* @description: Create string using both unicode and ascii chars; 
*/

//////////////////////////////////////////////////////////////////////////////
//CHECK#1
var __str = "\u0041A\u0042B\u0043C";
if (__str !== 'AABBCC'){
  $ERROR('#1: var __str = "\\u0041A\\u0042B\\u0043C"; __str === \'AABBCC\'. Actual: ' + (__str));
};
//
//////////////////////////////////////////////////////////////////////////////

//////////////////////////////////////////////////////////////////////////////
//CHECK#2
var __str__ = "\u0041\u0042\u0043"+'ABC';
if (__str__ !== 'ABCABC'){
  $ERROR('#2: var __str__ = "\\u0041\\u0042\\u0043"+\'ABC\'; __str__ === \'ABCABC\'. Actual: ' + (__str__));
};
//
//////////////////////////////////////////////////////////////////////////////

//////////////////////////////////////////////////////////////////////////////
//CHECK#3
var str__ = "ABC"+'\u0041\u0042\u0043';
if (str__ !== "ABCABC"){
  $ERROR('#2: var str__ = "ABC"+\'\\u0041\\u0042\\u0043\'; str__ === "ABCABC". Actual: ' + (str__));
};
//
//////////////////////////////////////////////////////////////////////////////