[dylan-lang/testworks] b31b52: Add expected-failure support.

GitHub <[email protected]> Tue, 15 Sep 2015 00:55:22 -0700
Newsgroups gmane.comp.lang.dylan.gwydion.cvs
Message-ID <55f7ceeae7ca6_1d233fd2ad69f2c0420423d@hookshot-fe5-cp1-prd.iad.github.net.mail>
  Branch: refs/heads/expected-failure
  Home:   https://github.com/dylan-lang/testworks
  Commit: b31b52e2fce85d1e5801d2d779af345aa0607d9c
      https://github.com/dylan-lang/testworks/commit/b31b52e2fce85d1e5801d2d779af345aa0607d9c
  Author: Bruce Mitchener <[email protected]>
  Date:   2015-09-15 (Tue, 15 Sep 2015)

  Changed paths:
    M coloring.dylan
    M components.dylan
    M documentation/users-guide/source/reference.rst
    M documentation/users-guide/source/usage.rst
    M library.dylan
    M reports.dylan
    M results.dylan
    M run.dylan
    M tests/testworks-test-suite.dylan

  Log Message:
  -----------
  Add expected-failure support.

It is useful to be able to note that a test is expected to fail
and to note when it unexpectedly succeeds.  This will be useful
for the Dylan test suites where we have some long-standing failures
that can be flagged as expecting to fail so that we will notice
new failures or other changes in the status of tests.

Fixes bug #72.

* components.dylan
  (%expected-failure?): New slot on <runnable>, parent class for
    both <test> and <benchmark>.
  (expected-failure?): New method to see if a test is expected
    to fail. This inspects %expected-failure? and evaluates the
    method if there is one.

* results.dylan
  ($expected-failure, $unexpected-success): New status values.
  (<result-status>): Update to include new status values.
  (status-name): Update to handle new status values.

* reports.dylan
  (count-results): Count $expected-failure as a pass, $unexpected-success
    as a failure.

* coloring.dylan
  ($expected-failure-attributes, $unexpected-success-attributes): New
    text attributes.
  (result-status-to-attributes): Map new status values to new text attributes.

* run.dylan
  (execute-component on <suite>): Count an $expected-failure result as
    a passing result.
  (execute-component on <test>): Check expected-failure? to handle
    $passed and $failed correctly.

* library.dylan
  (module %testworks): Export $expected-failure and $unexpected-success.

* documentation/users-guide/source/reference.rst
  (test-definer, benchmark-definer): Update to discuss expected-failure?.

* documentation/users-guide/source/usage.rst
  (Tests): Update to discuss expected failures.

* tests/testworks-test-suite.dylan: Update to test expected failure and
  unexpected success scenarios.

_______________________________________________
chatter mailing list
[email protected]
https://lists.opendylan.org/mailman/listinfo/chatter