This commit is contained in:
Misko Hevery 2010-01-28 20:44:34 -08:00
parent 473e57e225
commit 3d99e0f6de
5 changed files with 15 additions and 2 deletions

View file

@ -26,6 +26,7 @@ var consoleNode, jQuery, msie,
angular = window['angular'] || (window['angular'] = {}),
angularValidator = angular['validator'] || (angular['validator'] = {}),
angularFilter = angular['filter'] || (angular['filter'] = {}),
angularFormater = angular['formater'] || (angular['formater'] = {}),
angularCallbacks = angular['callbacks'] || (angular['callbacks'] = {}),
angularAlert = angular['alert'] || (angular['alert'] = function(){
log(arguments); window.alert.apply(window, arguments);

6
src/Formaters.js Normal file
View file

@ -0,0 +1,6 @@
extend(angularFormater, {
'noop':function(){
}
});

View file

@ -95,7 +95,7 @@ Scope.prototype = {
},
eval: function(expressionText, context) {
log('Scope.eval', expressionText);
// log('Scope.eval', expressionText);
var expression = Scope.expressionCache[expressionText];
if (!expression) {
var parser = new Parser(expressionText);

View file

@ -204,7 +204,7 @@ ApiTest.prototype.testQuoteString = function(){
};
ApiTest.prototype.testQuoteStringBug = function(){
assertEquals(angular.String.quote('"7\\\\\\\"7"', "7\\\"7"));
assertEquals(angular.String.quote("7\\\"7"), '"7\\\\\\\"7"');
};
ApiTest.prototype.testQuoteUnicode = function(){

6
test/FormatersTest.js Normal file
View file

@ -0,0 +1,6 @@
TestCase("formaterTest", {
testNoop: function(){
assertEquals("abc", angular.formater.noop("abc"));
assertEquals("xyz", angular.formater.noop("abc", "xyz"));
}
});