Index: test/intl/collator/de-sort.js |
diff --git a/src/extensions/i18n/header.js b/test/intl/collator/de-sort.js |
similarity index 74% |
copy from src/extensions/i18n/header.js |
copy to test/intl/collator/de-sort.js |
index 1c0a2d8874b5aa982ca2be2fb39f2ead1c4a9622..78dfcb32e37e2e38023232835261b36ef57a4091 100644 |
--- a/src/extensions/i18n/header.js |
+++ b/test/intl/collator/de-sort.js |
@@ -26,16 +26,20 @@ |
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
// limitations under the License. |
-// ECMAScript 402 API implementation is broken into separate files for |
-// each service. The build system combines them together into one |
-// Intl namespace. |
+// Sort plain German text using defaults. |
-/** |
- * Intl object is a single object that has some named properties, |
- * all of which are constructors. |
- */ |
-var Intl = (function() { |
+var strings = ['März', 'Fuße', 'FUSSE', 'Fluße', 'Flusse', |
+ 'flusse', 'fluße', 'flüße', 'flüsse']; |
-'use strict'; |
+var collator = Intl.Collator(['de']); |
+var result = strings.sort(collator.compare); |
-var Intl = {}; |
+assertEquals('flusse', result[0]); |
+assertEquals('Flusse', result[1]); |
+assertEquals('fluße', result[2]); |
+assertEquals('Fluße', result[3]); |
+assertEquals('flüsse', result[4]); |
+assertEquals('flüße', result[5]); |
+assertEquals('FUSSE', result[6]); |
+assertEquals('Fuße', result[7]); |
+assertEquals('März', result[8]); |