| Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
- turn everything into a directive
|
|
|
|
- $injector('abc') -> $injector.get('abc');
- $injector(fn) -> $injector.invoke(null, fn);
|
|
|
|
|
|
- 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
|
|
New $location does not have hashSearch, hashPath.
The old dsl was mixing $location / window.location so this solves the problem as well...
|
|
|
|
|
|
|
|
since jQuery 1.6.4 attr() focuses only on work with element attributes and doesn't deal well with element properties, so adding prop() support is required for getting many e2e tests to pass after upgrading the runner to jQuery 1.6.4.
|
|
for special attrs like 'checked' or 'multiple', jquery now returns the name or undedefined.
e.g. foo.attr('checked') => 'checked' || undefined
The solution is a combination of updating our tests as well as switching
over to prop() instead which properly returns true/false
|
|
This is jQuery incompatible hack.
But we were doing monkey patching there anyway...
`$(...).trigger('click')` returns an array of return values, so that scenario
runner knows, whether the event default action was cancelled.
Without this fix, scenario runner was doing navigation even if JS code called
`event.preventDefault()`.
Note, this does not work in FF6
|
|
- 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
|
|
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
|
|
Closes #237
|
|
Closes #207
|
|
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...
|
|
This is a combination of 4 commits:
* Fix some small typos, missing semi-colons, etc.
* Fix comment for angular.scenario.SpecRunner.run method
* Fixed some missing semi-colons in cookbook
* Fixed missing semi-colon in nodeserver/server.js
|
|
|
|
camelcase is used for other angular functions and forEach is also
used by EcmaScript standard.
- rename the internal as well as the external function name
- tweak the implementation of the function so that it doesn't
clober it self when we extend the angular object with an
object that has a forEach property equal to this forEach function
Closes #85
|
|
|
|
Closes #134
|
|
BACKWARD INCOMPATIBLE: removed ssn validators, since it is unlikely that most people will need it and if they do, they can added it thorough RegExp
|
|
|
|
|
|
|
|
|
|
methods properly
|
|
|
|
move navigateTo() under the browser DSL.
|
|
|
|
e.g.
Before:
code: element('.actions ul li a').click();
output: element .actions ul li a click
After
code: element('.actions ul li a', "'Configuration' link").click();
output: element 'Configuration' link ( .actions ul li a ) click
|
|
failure behavior.
|
|
ng-binding
|
|
|
|
- By default the runner now creates multiple output formats as it runs. Nodes are created in the DOM with ids: json, xml, and html.
ex. $('#json').html() => json output of the runner
ex. $('#xml').html() => json output of the runner
$result is also an object tree result.
The permitted formats are html,json,xml,object.
If you don't want certain formats you can select specific ones with the new ng:scenario-output attribute on the script tag.
<script src="angular-scenario.js" ng:scenario-output="xml,json">
- Added element(...).count() that returns the number of matching elements for the selector.
- repeater(...).count() now returns 0 if no elements matched which can be used to check if a repeater is empty.
- Added toBe() matcher that does strict equality with ===
- Implement iit and ddescribe. If iit() is used instead of it() then only that test will run. If ddescribe() is used instead of describe() them only it() statements inside of it will run. Several iit/ddescribe() blocks can be used to run isolated tests.
- Implement new event based model for SpecRunner. You can now listen for events in the runner. This is useful for writing your own UI or connecting a remote process (ex. WebDriver). Event callbacks execute on the Runner instance.
Events, if fired, will always be in the below order. All events always happen
except for Failure and Error events which only happen in error conditions.
Events:
RunnerBegin
SpecBegin(spec)
StepBegin(spec, step)
StepError(spec, step, error)
StepFailure(spec, step, error)
StepEnd(spec, step)
SpecError(spec, step, error)
SpecEnd(spec)
RunnerEnd
- Only allow the browser to repaint every 10 steps. Cuts 700ms off Firefox in benchmark, 200ms off Chrome.
- Bug Fix: Manually navigate anchors on click since trigger wont work in Firefox.
|
|
on all browsers
|
|
latest. Cleanup whitespace.
|
|
|
|
Polish the Scenario Runner UI to include:
- a scroll pane that steps appear in since the list can be very long
- Collapse successful tests
- Show the line where the DSL statements were when there's an error (Chrome, Firefox)
Also:
- Remove lots angular.bind calls to reduce the amount of stack space used.
- Use setTimeout(...,0) to schedule the next future to let the browser breathe and have it repaint the steps. Also prevents overflowing the stack when an it() creates many futures.
- Run afterEach() handlers even if the it() block fails.
- Make navigateTo() take a function as the second argument so you can compute a URL in the future.
- Add wait() DSL statement to allow interactive debugging of tests.
- Allow custom jQuery selectors with element(...).query(fn) DSL statement.
Known Issues:
- All afterEach() handlers run even if a beforeEach() handler fails. Only after handlers for the same level as the failure and above should run.
|
|
- Also fixed angular.suffix for scenarios
- refactored click() to browserTrigger()
- Fixed Rakefile with CSS and jQuery
|
|
more DSL statements.
- "this" always means the current chain scope inside a DSL
- addFutureAction callbacks now take ($window, $document, done)
- $document has a special method elements() that uses the currently selected nodes in the document as defined by using() statements.
- $document.elements() allows placeholder insertion into selectors to make them more readable.
ex. $document.elements('input[name="$1"]', myVar) will substitute the value of myVar for $1 in the selector. Subsequent arguments are $2 and so on.
- $document.elements() results have a special method trigger(event) which should be used to events. This method implements some hacks to make sure browser UI controls update and the correct angular events fire.
- futures now allow custom formatting. By default any chain that results in a future can use toJson() or fromJson() to convert the future value to and from json. A custom parser can be provided with parsedWith(fn) where fn is a callback(value) that must return the parsed result.
Note: The entire widgets.html UI is now able to be controlled and asserted through DSL statements!!! Victory! :)
|