tests/test-run-tests.t
changeset 35069 4fb489a998c9
parent 34969 d600bda4a3e1
child 35097 fc0f3ed071fc
equal deleted inserted replaced
35068:57c79542bebb 35069:4fb489a998c9
  1501   !.
  1501   !.
  1502   Failed test-cases-abc.t (case B): output changed
  1502   Failed test-cases-abc.t (case B): output changed
  1503   # Ran 2 tests, 0 skipped, 1 failed.
  1503   # Ran 2 tests, 0 skipped, 1 failed.
  1504   python hash seed: * (glob)
  1504   python hash seed: * (glob)
  1505   [1]
  1505   [1]
       
  1506 
       
  1507 Test automatic pattern replacement
       
  1508 
       
  1509   $ cat << EOF >> common-pattern.py
       
  1510   > substitutions = [
       
  1511   >     (br'foo-(.*)\\b',
       
  1512   >      br'\$XXX=\\1\$'),
       
  1513   >     (br'bar\\n',
       
  1514   >      br'\$YYY$\\n'),
       
  1515   > ]
       
  1516   > EOF
       
  1517 
       
  1518   $ cat << EOF >> test-substitution.t
       
  1519   >   $ echo foo-12
       
  1520   >   \$XXX=12$
       
  1521   >   $ echo foo-42
       
  1522   >   \$XXX=42$
       
  1523   >   $ echo bar prior
       
  1524   >   bar prior
       
  1525   >   $ echo lastbar
       
  1526   >   last\$YYY$
       
  1527   >   $ echo foo-bar foo-baz
       
  1528   > EOF
       
  1529 
       
  1530   $ rt test-substitution.t
       
  1531   
       
  1532   --- $TESTTMP/anothertests/cases/test-substitution.t
       
  1533   +++ $TESTTMP/anothertests/cases/test-substitution.t.err
       
  1534   @@ -7,3 +7,4 @@
       
  1535      $ echo lastbar
       
  1536      last$YYY$
       
  1537      $ echo foo-bar foo-baz
       
  1538   +  $XXX=bar foo-baz$
       
  1539   
       
  1540   ERROR: test-substitution.t output changed
       
  1541   !
       
  1542   Failed test-substitution.t: output changed
       
  1543   # Ran 1 tests, 0 skipped, 1 failed.
       
  1544   python hash seed: * (glob)
       
  1545   [1]