Commit graph

6618 commits

Author SHA1 Message Date
Tobias Boege
0c151bc812 gb.test: Subtest support for Assert
[GB.TEST]
* OPT: TapPrinter: use the Print method everywhere
* NEW: Add the TapPrinter_Filter event
* NEW: Assert: add subtest support
2018-06-09 22:42:27 +02:00
Tobias Boege
5e171d5a1c gb.test: Fix accounting in TestHarness
[GB.TEST]
* BUG: The test bonus is calculated correctly now
* BUG: Fix test success detection: all planned tests ran and no failures occurred
2018-05-25 14:40:16 +02:00
Tobias Boege
1ed40b6c85 gb.test: Simplify names for the "crashing test" test
[GB.TEST]
* OPT: Simplify names for the "crashing test" test
2018-05-25 14:30:15 +02:00
Tobias Boege
5613b9920d gb.test: Add Run member to TestStats
[GB.TEST]
* NEW: TestStats.Run counts the number of tests that were actually run
2018-05-23 22:36:03 +02:00
Tobias Boege
bf0e19c514 gb.test: Add a SelfTest for a crashing test
[GB.TEST]
* NEW: Add a SelfTest for a crashing test

Reported by Christof Thalhofer
2018-05-23 22:34:20 +02:00
Tobias Boege
78ade59842 gb.test: Fix test summary of startup class
[GB.TEST]
* BUG: Tester: The "Run Tests" statistic was calculated wrongly
2018-05-23 22:26:53 +02:00
Tobias Boege
33baf4da3a gb.test: Process a TAP stream in realtime and capture stderr
[GB.TEST]
* NEW: TestHarness: Don't buffer process output
* NEW: The testee's stderr is converted into diagnostic messages
* BUG: Remove (incorrect) usage of Error.Class from error reporting, Error.Where is sufficient
* BUG: TapPrinter: Always flush output in case the process dies suddenly
2018-05-23 22:25:39 +02:00
Tobias Boege
3097bf1ea2 gb.test: Assert.StringEquals for comparing long strings
[GB.TEST]
* NEW: Add Assert.StringEquals which writes diagnostics for why two strings are unequal

Sample output for a subtle case where it was helpful:

  not ok 2 - Output as expected
  # Strings are of different length.
  #   Got:      219
  #   Expected: 218
  # Strings differ at position 216
  #   Got:      " \n# "
  #   Expected: "\n# "
2018-05-23 22:12:29 +02:00
Tobias Boege
7dbb378ffb gb.test: Assert routines return the ok-ness
[GB.TEST]
* NEW: All routines in Assert return whether the assertion was positive
2018-05-23 22:11:01 +02:00
Tobias Boege
f30a3c1834 gb.test: Delete README
[GB.TEST]
* OPT: Delete README.md. Everything in it is obsolete
2018-05-19 02:18:08 +02:00
Tobias Boege
9a3ea3e4cb gb.test: Begin self-tests
[GB.TEST]
* NEW: Add self-tests
* NEW: Add provisional test runner
* BUG: TestHarness: Correctly initialise TestStats and actually run the parser
2018-05-19 02:14:55 +02:00
Tobias Boege
43fc4a56b2 gb.test: More cleanup
[GB.TEST]
* OPT: Delete TAP-incompatible classes and add TODOs
* BUG: Forgot to Export Tap
* NEW: Add comparisons to Assert
2018-05-19 01:52:38 +02:00
Tobias Boege
4c695dc703 gb.test: Fix compilation
[GB.TEST]
* BUG: 6a9035 and 1c2d0b did not compile
2018-05-19 00:26:36 +02:00
Tobias Boege
2e3a5aeb62 gb.test: Various cleanups
[GB.TEST]
* OPT: Cleanup component description and dependencies
* OPT: Remove useless data files
2018-05-19 00:24:33 +02:00
Tobias Boege
3681e003d6 Merge remote-tracking branch 'gb.unittest/TAP' into gb.test
[GB.TEST]
* NEW: Import (my fork of) Christof's gb.unittest from github as a new gb.test component
2018-05-18 23:41:16 +02:00
Tobias Boege
6a90351e0d Start the Assert module 2018-05-18 23:14:43 +02:00
Tobias Boege
1c2d0b4d8e TapPrinter: add properties
Properties Output, Plan, Count and Last were added to read the current
test state (plan, how many tests were run, the test number of the last
run test). In particular, allow the reconfiguration of the Output stream
after the object is created.
2018-05-18 23:12:15 +02:00
gambas
e528f3441a Fix compilation with poppler < 0.64.
[GB.PDF]
* BUG: Fix compilation with poppler < 0.64.
2018-05-16 02:24:20 +02:00
Tobias Boege
0893ca7dee gb.pdf: Fix compilation with older popplers
[GB.PDF]
* BUG: Fix compilation with older popplers
2018-05-16 02:04:47 +02:00
Adrien Prokopowicz
6c9f64666a
[GB.XML]
* BUG: Fix the XmlNode.GetElementsByAttributeValue() method.
2018-05-16 01:43:21 +02:00
Tobias Boege
fdf8fa658f gb.pdf: Compile with poppler 0.64
[GB.PDF]
* NEW: Add many consts to compile with poppler 0.64. Partial patch thanks to Tony Morehen
2018-05-15 21:27:51 +02:00
gambas
6858457dbb Automatic completion: Don't crash when completing an unreadable directory.
[DEVELOPMENT ENVIRONMENT]
* BUG: Automatic completion: Don't crash when completing an unreadable directory.
2018-05-14 01:18:11 +02:00
Benoît Minisini
df6bf93820 Merge branch 'master' into 'master'
This commit contains bug fix for the Chart component.

See merge request gambas/gambas!18
2018-05-13 21:20:21 +00:00
Adrien Prokopowicz
2ac99a0f2a
[GB.XML]
* BUG: Fix reading XML comments and CDATA tags when they contain
characters that belong to the end tag while not forming a complete one.
* BUG: Fix returning value of XML comments.

[GB.XML.HTML]
* BUG: Fix reading lowercase HTML doctypes.
2018-05-13 15:49:00 +02:00
gambas
dce6496cd9 Use text colors and not tooltip colors for form & image editors' information panel. Tooltip colors are sometimes unreadable.
[DEVELOPMENT ENVIRONMENT]
* NEW: Form editor: Use text colors and not tooltip colors for information panel. Tooltip colors are sometimes unreadable.
* NEW: Image editor: Use text colors and not tooltip colors for information panel.
2018-05-12 19:41:48 +02:00
gambas
2c2146d594 Merge branch 'master' of gitlab.com:gambas/gambas 2018-05-12 19:40:38 +02:00
gambas
352bf8230d Fix use of QFont::setStyleName()
[GB.QT4]
* BUG: Don't use QFont::setStyleName() if Qt version is not at least 4.8.

[GB.QT5]
* BUG: Call QFont::setStyleName() last, as it may be buggy if Qt version is not at least 5.3.
2018-05-12 19:38:38 +02:00
Benoît Minisini
386edd1f79 Merge branch 'patch-2' into 'master'
fix forgotten conditional, not property a bug, conserves minimal build requirements

See merge request gambas/gambas!20
2018-05-12 13:07:30 +00:00
PICCORO Lenz McKAY
7e622ba756 fix forgotten conditional, not property a bug, conserves minimal build requirements 2018-05-11 20:21:10 +00:00
gambas
d552008415 Add a flag for enabling link time optimization, and disable it by default.
[CONFIGURATION]
* NEW: Add a flag for enabling link time optimization, and disable it by default.
2018-05-10 09:13:15 +02:00
gambas
1701be8a34 Open project dialog: Always select the project filter text.
[DEVELOPMENT ENVIRONMNENT]
* BUG: Main window: Fix an english mistake in a menu entry.
* NEW: Open project dialog: Always select the project filter text.
2018-05-09 01:18:13 +02:00
gambas
14614f4e67 Check if the "-flto" link time optimzation flag is available.
[CONFIGURATION]
* BUG: Check if the "-flto" link time optimzation flag is available.
2018-05-08 18:44:31 +02:00
gambas
85376261ea DateBox: The time popup works correctly again.
[GB.FORM]
* BUG: DateBox: The time popup works correctly again.
2018-05-07 22:20:01 +02:00
Tobias Boege
6a77f9f2c5 Only use tag in trunk_version.h if it is *exactly* that commit
[CONFIGURATION]
* BUG: Only use tag in trunk_version.h if it is *exactly* that commit
2018-05-05 18:07:50 +02:00
Tobias Boege
9ed904241f Print git tag instead of branch name in trunk_version.h if available
[CONFIGURATION]
* NEW: Print git tag instead of branch name in trunk_version.h if available
2018-05-05 17:56:29 +02:00
Tobias Boege
e4bfb99a47 Generate trunk_version.h with detached HEAD
[CONFIGURATION]
* BUG: Generate trunk_version.h with detached HEAD
2018-05-05 17:56:29 +02:00
Davidmue
f61ff5e8b6 This commit contains bug fix for the Chart component.
[GB.CHART]
* BUG: Fixed a bug in Chart class.
  A more complex calculated id is now used. This let us use more than one chart.
* BUG: Fixed a bug in _CSerie class.
  A call to an unexisting property Labels has been changed.
2018-05-05 11:02:05 +02:00
gambas
a9f852d5c5 Farm client: Compile the project before publishing it, so that the project version is accurate in the case it is read from a VERSION file.
[DEVELOPMENT ENVIRONMENT]
* BUG: Farm client: Compile the project before publishing it, so that the project version is accurate in the case it is read from a VERSION file.
* BUG: Property sheet button icon is now different from project properties button icon.
2018-05-04 18:54:34 +02:00
gambas
7239cbe35e SmtpClient: Fix the sent date header.
[GB.NET.SMTP]
* BUG: SmtpClient: Fix the sent date header.
2018-05-02 17:05:16 +02:00
gambas
90b70ed78b The 'Clear all breakpoints' menu entry works again.
[DEVELOPMENT ENVIRONMENT]
* BUG: The 'Clear all breakpoints' menu entry works again.
2018-05-01 17:45:51 +02:00
gambas
f57ffd7354 Automatic completion: SUPER and ME always show all hidden symbols and update source archive exclude list.
[DEVELOPMENT ENVIRONMENT]
* NEW: Automatic completion: SUPER and ME always show all hidden symbols.
* NEW: Option dialog: Remove unused source archive configuration.
* NEW: Update source archives exclude list.
* BUG: Project tree: Modified classes correctly update their form icons.
* NEW: Update support file.
2018-04-28 16:00:12 +02:00
gambas
20f650aa59 Shortcut configuration dialog: Use the Shortcut class and display action icons correctly.
[GB.FORM.MDI]
* NEW: Shortcut configuration dialog: Use the Shortcut class.
* BUG: Shortcut configuration dialog: Display action icons correctly.
2018-04-28 15:54:33 +02:00
gambas
93fe4c8ae2 Shortcut: Write modifier keys with the first letter capitalized only.
[GB.GUI.BASE]
* BUG: Shortcut: Write modifier keys with the first letter capitalized only.
2018-04-28 15:53:17 +02:00
Tobias Boege
888e880c23 Implement TestHarness
TestHarness is a class which runs multiple tests and collects statistics
about them. It is inspired by perl's Test::Harness. It is the main
component of a program which tests other programs which output TAP.

The current design I'm implementing requires that unit tests are
implemented in classes outside of the unit they are testing, for the
following reasons:

  1. You should only test public interface anyway. Even if it is
     sometimes simpler to implement a test using private data of
     an object:
  2. It makes the class unnecessarily big and exposes methods which
     you don't want/need for a release.

This base class for implementing tests comes next. Tests are run in
an external process, by using the test as a startup class. This has
the benefit that the test harness isn't affected by a crash in the
test. It would be nice to have special treatment of tests in the
project directory structure, to list all tests in a project reliably
from the outside. IDE and compiler could benefit from that as well.
2018-04-27 01:15:15 +02:00
Tobias Boege
0929707aee Low-level printer and parser for TAP format
The Test Anything Protocol (TAP) is a text-based format for communicating
unit test results. It originated from perl and has a specification here:
http://testanything.org/
2018-04-25 13:05:09 +02:00
Christof Thalhofer
2d591f341b Refact 2018-04-22 15:38:27 +02:00
Christof Thalhofer
80127af1c2 Readme 2018-04-22 15:24:23 +02:00
Christof Thalhofer
4a8c8c7efb delete old gb.deg.unittest 2018-04-22 15:16:16 +02:00
Christof Thalhofer
129ff730a6 Correct TAP output 2018-04-22 15:13:55 +02:00
Christof Thalhofer
d96cd5c673 Unittest without GUI and with TAP output 2018-04-22 14:38:09 +02:00