You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Make test injector and test component builder (more) agnostic to the test environment #2783
The test_lib contains many helpers, but it's closely coupled with the Jasmine-style BDD environment. Decouple where possible - in particular, to enable running with the dart:test package, and to enable running in JavaScript outside of Angular's own repository.
Most of the things that the test lib does are not generalizable. They are simple functions that wrap around testing functions (like beforeEach and it). I think there is actually nothing that would be helpful to pull out - we should just have a separate adapter for dart:test.
There are also several matchers and spy functions, which may be nice to have but should be doable with basic dart:test and a mock library (dart recommends mockito).
Activity
juliemr commentedon Jul 1, 2015
In regards to dart:test:
Most of the things that the test lib does are not generalizable. They are simple functions that wrap around testing functions (like
beforeEachandit). I think there is actually nothing that would be helpful to pull out - we should just have a separate adapter for dart:test.There are also several matchers and spy functions, which may be nice to have but should be doable with basic dart:test and a mock library (dart recommends mockito).
kevmoo commentedon Jul 6, 2015
Agreeing with @juliemr. It'd be really nice if
guinnesswas split into helpers vs the imperative functions.naomiblack commentedon Jul 6, 2015
@juliemr can you figure out handoff if this one isn't landing before your OOO?
zzo commentedon Jul 7, 2015
is there documentation for how to use test_bed/TestComponentBuilder somewhere? Personally am only interested in the JS side of things thanks! :)
juliemr commentedon Jul 11, 2015
Update: I am stuck on some injector issues while decoupling - bumping to next milestone.
juliemr commentedon Jul 17, 2015
Here is a working example of a unit test written using dart:test, using the test injector and TestComponentBuilder: https://github.com/juliemr/angular/tree/test-lib-package-2/darttest
Next up I'll be adding useful helpers from test_lib.
16 remaining items
jasmine-standalone: plain html-page to run unit-tests.
juliemr commentedon Feb 25, 2016
This is largely done - most of the actual control is in the
testInjectornow. See #7266 for one remaining idea.angular-automatic-lock-bot commentedon Sep 8, 2019
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.