Misko Hevery
2430f52bb9
chore(module): move files around in preparation for more modules
2012-03-28 11:16:35 -07:00
Vojta Jina
00d4427388
refactor($provide) Rename service -> provider
...
It registers a provider class, so this makes more sense.
Breaks Rename $provide.service -> $provide.provider
2012-03-09 10:10:28 -08:00
Vojta Jina
64912069ca
docs(mock.inject): Fix the example
...
And explicitly say that you need to load your application modules that you wanna test.
2012-03-05 19:28:03 -08:00
Stephane Bisson
e86bafecd2
fix(mock.TzDate): getDay() takes into account the timezone offset
2012-02-29 15:53:51 -08:00
Misko Hevery
78656fe0df
feat($compile) add locals, isolate scope, transclusion
2012-02-21 22:46:00 -08:00
Misko Hevery
8af4fde182
add($compile): add compiler v2.0 - not connected
2012-01-25 11:46:36 -08:00
Misko Hevery
84823b2eff
feature($exceptionHandler): $exceptionHandler now supports var_args
2012-01-25 11:46:34 -08:00
Igor Minar
92af30ce6e
docs(*): various doc fixes
2012-01-17 09:49:37 -08:00
Igor Minar
54581d36df
fix(e2e $httpBackend): use browser.defer instead of $defer
...
this is necessary to avoid $apply from within $apply situations
2012-01-16 23:26:44 -08:00
Misko Hevery
5cdfe45aa3
feat(module): add runtime block
2012-01-13 14:28:43 -08:00
Igor Minar
16a40c626f
style(*): small fixes
2012-01-13 14:28:21 -08:00
Igor Minar
939c8e8fac
docs($http, $httpBackend): docs docs docs
2012-01-13 14:28:20 -08:00
Igor Minar
46691c2721
fix($http): remove support for PATCH + better whenXXX, expectXXX api
...
- there are too many unknowns about PATCH, so I'm dropping its support until we know that this is actually useful
- expectGET, expectHEAD and expectJSON (and the same for whenXXX) should not require response data to be specified
2012-01-13 13:53:07 -08:00
Vojta Jina
5164ae545b
style(mocks): remove console.log
2012-01-13 00:37:16 -08:00
Misko Hevery
e1e0ddb910
docs(inject/module): add documentation
2012-01-12 17:10:48 -08:00
Misko Hevery
d648d709f3
refactor(module): strict separation between module-config / app-runtime
2012-01-12 13:40:07 -08:00
Vojta Jina
9a8dbfef51
style(mock): make jslint and igor happier
2012-01-11 22:11:06 -08:00
Vojta Jina
28114de8dc
refactor(mock.$httpBackend): split (e2e/unit testing version of $httpBackend mock)
2012-01-11 22:11:01 -08:00
Vojta Jina
c6ea1be053
fix(mock.$httpBackend): resetExpectations should not create new array
2012-01-11 11:48:03 -08:00
Misko Hevery
5143e7bf06
feat(module): new module loader
2012-01-10 22:27:00 -08:00
Igor Minar
7146f70636
fix($httpBackend): fix for jsonp requests
2012-01-09 14:38:32 -08:00
Igor Minar
b8960c3710
chore($http): small $http fixes
2012-01-09 13:17:48 -08:00
Igor Minar
67338ce061
feat($http): turn mock backend into a decorator + e2e testing support
...
- provider -> decorator
- autoflush + passThrough mode
- fix noop -> angular.noop
2012-01-09 13:17:48 -08:00
Igor Minar
b911e303ec
feat($httpBackend): add expect/when shortcut methods
2012-01-09 13:17:48 -08:00
Igor Minar
a13b5ed3bc
fix($http): fix and cleanup $http and friends
...
$http:
- use promises internally
- get rid of XhrFuture that was previously used internally
- get rid of $browser.defer calls for async stuff (serving from cache),
promises will take care of asynchronicity
- fix transformation bugs (when caching requested + multiple request
pending + error is returned)
- get rid of native header parsing and instead just lazily parse the
header string
$httpBackend:
- don't return raw/mock XMLHttpRequest object (we don't use it for
anything anymore)
- call the callback with response headers string
mock $httpBackend:
- unify response api for expect and when
- call the callback with response headers string
- changed the expect/when failure error message so that EXPECTED and GOT
values are aligned
Conflicts:
src/service/http.js
test/service/compilerSpec.js
test/service/httpSpec.js
2012-01-09 13:17:48 -08:00
Igor Minar
63cca9afbc
feat(browser.defer): flush should throw exception when queue is empty
2012-01-09 13:17:48 -08:00
Igor Minar
bb2e7488fa
fix($httpBackend mock): getResponseHeader should be case insensitive
2011-12-01 18:21:45 -05:00
Igor Minar
bf8e0540f8
feat(dump): add support for arrays, functions, errors
2011-11-30 14:49:35 -05:00
Vojta Jina
9b4efa73f9
feat(mock.$httpBackend): say which request was expected when unexpected request error
2011-11-30 11:17:24 -05:00
Vojta Jina
4aaa2f7f6b
feat(mock.$httpBackend): verify expectations after flush()
2011-11-30 11:17:24 -05:00
Vojta Jina
6290bd4587
refactor(mock.$httpBackend): rename when().then() to when().respond()
2011-11-30 11:17:24 -05:00
Vojta Jina
e9f81b6631
fix(mock.$httpBackend): flush() even requests sent during callbacks
2011-11-30 11:17:23 -05:00
Vojta Jina
afbe073121
feat(mock.$httpBackend): add verifyNoOutstandingRequest method
...
+ rename verifyExpectations to verifyNoOutstandingExpectation
2011-11-30 11:17:23 -05:00
Vojta Jina
a4c8ac7126
feat(mock.$httpBackend): throw when nothing to flush, dump data/headers when expected different
2011-11-30 11:17:23 -05:00
Vojta Jina
5ad0c7d0e4
feat($httpBackend): extract $browser.xhr into separate service
...
- remove whole $browser.xhr stuff
- remove whole mock $browser.xhr stuff
- add $httpBackend service + migrate unit tests from $browser
- add temporary API to access $browser's outstandingRequests count
2011-11-30 11:17:22 -05:00
Vojta Jina
540701a8d8
feat(mocks.$browser): add simple addJs() method into $browser mock
2011-11-30 11:17:22 -05:00
Vojta Jina
cd28a2e952
feat(mocks.$httpBackend): add $httpBackend mock
...
$httpBackend mock allows:
- expecting (asserting) requests
- stubbing (responding without asserting)
Add empty $httpBackend service (currently just wrapper for $browser.xhr)
2011-11-30 11:12:14 -05:00
Vojta Jina
0c8b35681e
feat($browser): xhr returns raw request object
2011-11-30 11:03:41 -05:00
Misko Hevery
e88dfb734a
refactor(injector): $injector is no longer a function.
...
- $injector('abc') -> $injector.get('abc');
- $injector(fn) -> $injector.invoke(null, fn);
2011-11-14 20:31:19 -08:00
Vojta Jina
acbd7cdf32
style(docs): make jslint happy - fix some warnings
2011-11-14 20:31:19 -08:00
Misko Hevery
b09595a3c1
fix(doc) cleanup all api doc link warnings
2011-11-14 20:31:18 -08:00
Misko Hevery
f0fa5e6376
doc(AUTO, NG_MOCK): Documenting the AUTO and NG_MOCK module
2011-11-14 20:31:16 -08:00
Misko Hevery
9c06394376
chore(scenario tests): make scenario tests pass again
2011-11-14 20:31:15 -08:00
Misko Hevery
78c7066422
refactor(angular): isDate / isArray test iframe independent fix
2011-11-14 20:31:14 -08:00
Misko Hevery
a87f2fb9e4
refactor(mock): moved mocks into its own module
2011-11-14 20:31:14 -08:00
Misko Hevery
3972d2a89b
refactor(json): break dependence on api.js
2011-11-14 20:31:13 -08:00
Misko Hevery
16597e8b52
refactor($service): removed almost all references to scope.$service
...
- still need to remove from factory
2011-11-14 16:39:33 -08:00
Misko Hevery
bd04316a89
refactor(services): migrate angular.service -> module
2011-11-14 16:39:33 -08:00
Igor Minar
bacc31bea9
fix(defer.cancel): should return false instead of undefined
2011-10-22 21:32:48 -07:00
Igor Minar
ad90c3574f
feat($defer): add $defer.cancel
...
This functionality was previously available only as obscure $browser.defer.cancel.
I also added docs and tests and fixed an issue in .defer.cancel mock.
2011-10-22 21:32:48 -07:00