issue #7

Part 1 of implementing Asynchronous Validation. There are a few TODO's
but I have started on restructuring the code to distinguish between
synchronous and asynchronous validation. Part of this refactor was to
ensure that current behavior remains unchanged. The next step will be to
implement actual asynchronous validation. There are numerous other
concerns, such as the impact on compound constraints and such. I have
annotated such concerns with TODO's.
issue #7

Part 1 of implementing Asynchronous Validation. There are a few TODO's
but I have started on restructuring the code to distinguish between
synchronous and asynchronous validation. Part of this refactor was to
ensure that current behavior remains unchanged. The next step will be to
implement actual asynchronous validation. There are numerous other
concerns, such as the impact on compound constraints and such. I have
annotated such concerns with TODO's.
Committing so that I can merge changes from master.
issue #7

First shot at implementation of asynchronous validation. Includes
support for asynchronous compound constraints (i.e., a compound
constraints where one or more of the composing contraints is an
asynchronous constraint) as well. The tests that I will be writing next
will see if my implementation actually works.
issue #7

There was an issue to fix. Consider a compound constraint that contains
another compound constraint. Assume that we override the second
constraint such that it contains an asynchronous constraint. This means
that the parent constraint must also be marked async. Prior to this
commit, this was not the case. This commit should fix the issue. I did
this by adding a "parent" attribute to a CompositionGraph node and then
walking up the tree until the root node.
issue #7

Removing TODO comment.
Merging.
issue #7

Removing dependency on ConstraintService from CompositionGraph.
issue #7

Adding a test server to test async tests.
issue #7

Added tests for asynchronous validation. Also made changes to validation
logic. Earlier I was assuming that presence of one or more asynchronous
constraints meant that the entire set of constraints needed to be
validated asynchronously. This would never work because synchronous
constraints return values and do not call callbacks to report their
results. I have fixed this by splitting the constraints into synchronous
and asynchronous and then validating each one separately and then
combining the constraint violations. For grouped constraints, I have
taken independent and dependent group validation into account as well.
In short, it should behave exactly like synchronous validation. Of
course, I will only know for sure when I write tests :). But this is a
good start.
issue #7

Added one more test. Still need to add more. Modified the function that
asynchronously validates un-grouped constraint contexts. Previosuly it
would fire off asynchronous-validation calls sequentially, which wasn't
very performant. Now the function will fire off all requests in one go.
This means that asynchronous validation requests can occur in parallel
(on the server-side anyway).
issue #7

Added more tests, and identified and fixed some bugs that I found while
writing my tests :). Still need to add tests that involve compound
constraints that are composed of one or more asynchronous constraints.
Also need to check coverage.
issue #7

Added some tests for regula.compound. More to come.
issue #7

Adding more tests for regula.override. Fixed issues with cloning. Added
'parents' property to graph node (within CompositionGraph). We basically
have parallel DAGs; one going down from root to leaf nodes (i.e., native
or non-compound constraints) and one going up from leaf nodes to root.
issue #7

Additional tests. Ran JSCover and there are a few coverage-holes to fix.
issue #7

Adding more tests. Added a test to validate a compound constraint
containing a mix of sync and async constraints.
issue #7

Added more tests.
issue #7

Finished most of the async tests. I still have to write tests for
async-validation of form-specific constraints and radio groups. I
changed the behavior of regula#validate with respect to throwing errors.
In short, errors about constraints not being found will only be thrown
if elements are specified in conjunction with groups, constraints, or
groups and constraints. So calling regula.validate on just groups,
constraints, or groups and constraints which results in a situation
where there are no elements bound, will not result in an exception.
issue #7

Removed commented-out code. I am glad this is gone because it was pretty
strange and weird code that was pretty hacky.
issue #7

Added tests for async testing of form-specific constraints and
radio-groups. This takes care of all testing necessary for asynchronous
constraints. At some point I should probably look at getting the
branch-coverage up. Luckily it is at 87%. Also updated the version of
JSCover.

This commit is also the last one for the asynchronous-validation
feature.