PHP Classes

File: vendors/select2/tests/options/translation-tests.js

Recommend this page to a friend!
  Classes of Jorge Castro   Gentelella BladeOne   vendors/select2/tests/options/translation-tests.js   Download  
File: vendors/select2/tests/options/translation-tests.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: Gentelella BladeOne
Render templates using Bootstrap for presentation
Author: By
Last change:
Date: 3 years ago
Size: 633 bytes
 

Contents

Class file image Download
module('Options - Translations'); var $ = require('jquery'); var Options = require('select2/options'); test('partial dictionaries can be passed', function (assert) { var options = new Options({ language: { searching: function () { return 'Something'; } } }); var translations = options.get('translations'); assert.equal( translations.get('searching')(), 'Something', 'The partial dictionary still overrides translations' ); assert.equal( translations.get('noResults')(), 'No results found', 'You can still get English translations for keys not passed in' ); });