aboutsummaryrefslogtreecommitdiffstats
path: root/test/BinderSpec.js
AgeCommit message (Collapse)Author
2012-04-03feat(ngModel): update model on each key stroke (revert ngModelInstant)Vojta Jina
It turns out that listening only on "blur" event is not sufficient in many scenarios, especially when you use form validation you always had to use ngModelnstant e.g. if you want to disable a button based on valid/invalid form. The feedback we got from our apps as well as external apps is that the ngModelInstant should be the default. In the future we might provide alternative ways of suppressing updates on each key stroke, but it's not going to be the default behavior. Apps already using the ngModelInstant can safely remove it from their templates. Input fields without ngModelInstant directive will start propagating the input changes into the model on each key stroke.
2012-03-26refactor(ngBindAttr): removeVojta Jina
Breaks ng-bind-attr directive removed
2012-03-09chore(*): refactor all ng: to ng-Igor Minar
2012-02-28refactor(forms): Even better formsVojta Jina
- remove $formFactory completely - remove parallel scope hierarchy (forms, widgets) - use new compiler features (widgets, forms are controllers) - any directive can add formatter/parser (validators, convertors) Breaks no custom input types Breaks removed integer input type Breaks remove list input type (ng-list directive instead) Breaks inputs bind only blur event by default (added ng:bind-change directive)
2012-02-21fix(ng:repeat): use transclusionMisko Hevery
2012-02-21feat(directive): event now accessible as $eventMisko Hevery
Closes 259
2012-01-29refactor(binder): replace jested assertions with jasmineVojta Jina
2012-01-25refactor(directives): connect new compilerMisko Hevery
- turn everything into a directive
2012-01-12refactor(module): strict separation between module-config / app-runtimeMisko Hevery
2012-01-03style: prefer single quotes + some whitespacesVojta Jina
2012-01-03refactor: remove old JSTD assertionsVojta Jina
So that we can run the tests even without JSTD :-D
2011-11-14refactor(mock): moved mocks into its own moduleMisko Hevery
2011-11-14refactor($service): removed almost all references to scope.$serviceMisko Hevery
- still need to remove from factory
2011-11-14refactor(services): migrate angular.service -> moduleMisko Hevery
2011-11-14refactor(injector): switch to injector 2.0 introduce modulesMisko Hevery
2011-11-14refactor(compiler) turn compiler into a serviceMisko Hevery
BREAK - remove angular.compile() since the compile method is now a service and needs to be injected
2011-11-14refactor(injector): turn scope into a serviceMisko Hevery
- turn scope into a $rootScope service. - injector is now a starting point for creating angular application. - added inject() method which wraps jasmine its/beforeEach/afterEach, and which allows configuration and injection of services. - refactor tests to use inject() where possible BREAK: - removed angular.scope() method
2011-10-11chore(formating): clean code to be function() {Misko Hevery
2011-10-11feat(forms): new and improved formsMisko Hevery
2011-10-11refactor(bindings): remove the decoration of the DOM with errors.Misko Hevery
Only $exceptionHandler gets notified now.
2011-10-11feat(ng:repeat) collection items and DOM elements affinity / stabilityMisko Hevery
2011-09-01fix(ng:class): make ng:class friendly towards other code adding/removing classesIgor Minar
ng:class as well as ng:class-odd and ng:class-even always reset the class list to whatever it was before compilation, this makes it impossible to create another directive which adds its own classes on the element on which ng:class was applied. the fix simply removes all classes that were added previously by ng:class and add classes that the ng:class expression evaluates to. we can now guarantee that we won't clobber stuff added before or after compilation as long as all class names are unique. in order to implement this I had to beef up jqLite#addClass and jqLite#removeClass to be able to add/remove multiple classes without creating duplicates.
2011-08-12refactor(scope): remove $flush/$observe ng:eval/ng:eval-orderMisko Hevery
2011-08-02feat(scope): new and improved scope implementationMisko Hevery
- Speed improvements (about 4x on flush phase) - Memory improvements (uses no function closures) - Break $eval into $apply, $dispatch, $flush - Introduced $watch and $observe Breaks angular.equals() use === instead of == Breaks angular.scope() does not take parent as first argument Breaks scope.$watch() takes scope as first argument Breaks scope.$set(), scope.$get are removed Breaks scope.$config is removed Breaks $route.onChange callback has not "this" bounded
2011-07-18feat(strict mode): adding strict mode flag to all js filesIgor Minar
the flag must be in all src and test files so that we get the benefit of running in the strict mode even in jstd the following script was used to modify all files: for file in `find src test -name "*.js"`; do echo -e "'use strict';\n" > temp.txt cat $file >> temp.txt mv temp.txt $file done
2011-06-08Added ng:options directiveMisko Hevery
Closes #301
2011-06-08Throw error when compiling multiple rootsMisko Hevery
Closes #338
2011-06-08Cleanup parser code to expose smaller APIMisko Hevery
2011-06-02Fix CSS tests on OperaVojta Jina
Opera translates name colors to numbers (red -> #ff0000) Other browsers like FF or Chrome translate number to rgb (#ff0000 -> rgb(255, 0, 0) So avoiding colors in tests is probably the easiest solution...
2011-03-01linking function should return bound scopeIgor Minar
angular.compile()() returns {scope:scope, view:view}, this isn't useful at all and only makes tests more verbose. Instead, this change makes the linking function return scope directly and if anyone needs the linked dom there are two ways to do it documented in angular.compile. other changes: - moved angular.compile docs to the compiler so that they are closer to the compiler - fixed some typos and updated angular.compile docs with the new return value
2011-02-18Remove ng:watchMisko Hevery
Closes#143
2011-02-16Changed the angular.compile(element)(scope[, cloneAttachNode])Misko Hevery
2011-02-16Change API angular.compile(element)([scope], [element/true])Misko Hevery
2011-02-16remove $init on scope from applying compilation templateMisko Hevery
Closes #40
2011-01-26split mocks and create $log and $exceptionHandler mocksIgor Minar
- split mocks between angular-mocks.js and mocks.js - src/angular-mocks.js now contains only mocks that we want to ship - test/mocks.js contains mocks that we use internally for testing angular - created angular.mock namespace - created public $exceptionHandler mock rethrows errors - created public $log mock stores all logs messages in an array that can be accessed to make assertions - internally we now have factory to create $exceptionHandler that we can assert on - internally we also keep track of all messages logged and fail tests if messages were not expected and cleaned up (checked via global beforeEach and afterEach) - updated RakeFile and docs reader.js to point to the new angular-mocks.js location - made real $exceptionHandler and $log factories accessible from tests and simplified their specs - fixed typos in several spec descriptions - added log assertions throughout the test suite
2011-01-24fixed example rendering, add tests for it.Misko Hevery
2011-01-07change to keydown from keyup; add delayed $updateViewMisko Hevery
- There was a perceived lag when typing do to the fact that we were listening on the keyup event instead of keydown. The issue with keydown is that we can not read the value of the input field. To solve this we schedule a defer call and perform the model update then. - To prevent calling $eval on root scope too many times as well as to prevent drowning the browser with too many updates we now call the $eval only after 25ms and any additional requests get ignored. The new update service is called $updateView
2011-01-06converted last of tests to specsMisko Hevery