Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct typos #370

Closed
wants to merge 1 commit into from
Closed

Correct typos #370

wants to merge 1 commit into from

Conversation

jostber
Copy link
Contributor

@jostber jostber commented Jan 12, 2015

[ci]

@@ -512,7 +512,7 @@ Ledger will generate:

@smallexample @c output:66E3A2C
10-Dec-01 Checking balance Assets:Checking $ 1,000.00 $ 1,000.00
Equit:Opening Balances $ -1,000.00 0
Equity:Opening Balances $ -1,000.00 0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This MUST NOT be merged.

As explained in the beginning of ledger3.texi, the examples provided in documentation are validated with ledger command. Here, by adding a 'y', you are modifying the ledger output. As DocTests.py is checking that ledger3.texi is the same as ledger output, this fails...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @jostber,
as @thdox already stated the proposed changes break the ledger validation.

Please take a moment to read the rather lengthy (but very worthwhile ;) comment at the beginning of doc/ledger3.texi it sheds some light on how examples in the documentation are validated
to ensure that the given examples do actually work with ledger.

There are different ways of running the DocTests:

  • python test/DocTests.py -vv --ledger ${PATH_TO}/ledger --file ${PATH_TO}/doc/ledger3.texi
  • ctest --output-on-failure -R DocTests (which just runs the above command for you)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On my system (debian wheezy), on branch master, the two commands does not produce the same output. Any idea ?

~/dev/ledger$ python test/DocTests.py -l ./ledger -f doc/ledger3.texi
...............................................................................................................................................................................

~/dev/ledger$ python test/DocTests.py -vv --ledger ./ledger --file ./doc/ledger3.texi | grep 82150D9
82150D9 : Passed

~/dev/ledger$ ctest --output-on-failure -R DocTests
Test project /home/thierry/dev/ledger
Start 1: DocTestsTest_ledger
1/3 Test #1: DocTestsTest_ledger .............. Passed 0.14 sec
Start 2: DocTestsTest_ledger-mode
2/3 Test #2: DocTestsTest_ledger-mode ......... Passed 0.06 sec
Start 3: DocTestsTest_ledger3
3/3 Test #3: DocTestsTest_ledger3 .............***Failed 4.94 sec
..................................................................................................................E............................................................

The following examples failed:
82150D9

67% tests passed, 1 tests failed out of 3

Total Test time (real) = 5.17 sec

The following tests FAILED:
3 - DocTestsTest_ledger3 (Failed)
Errors while running CTest

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @thdox,
that's quite odd. At the moment I have no idea or explanation why this may be. Thanks for taking this issue to the list; I will respond there once I've done some more investigation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants