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

Tests: use JMockit to enable more extensive test coverage #24

wants to merge 32 commits into from
Commits on Jul 21, 2018
  1. unit tests: replace isHeadless checks in NavigatableComponent & MapVi…

    risicle committed Feb 8, 2018
    …ewState with uses of jmockit
  2. JOSMTestRules: clear JosmBaseDirectories memo-ized values to ensure n…

    risicle committed Feb 21, 2018
    …ew josm home setting takes effect
    This requires adding a new public method to JosmBaseDirectories but
    otherwise our new home directory setting has no effect and contents between
    tests are liable to collide.
  3. testing: add JOptionPaneSimpleMocker

    risicle committed Mar 18, 2018
    Unfortunately also requires making ConditionalOptionPaneUtil.MessagePanel
  4. JOSMTestRules: don't use setProperty to (unreliably) trick awt into t…

    risicle committed Feb 25, 2018
    …hinking it's in headless mode
    ...when in fact it's not. Thinking it's in headless mode causes JOSM's tests
    to skip whole swathes of code which should be tested.
  5. JOSMTestRules: add EDTAssertionMocker and .assertionsInEDT() method f…

    risicle committed Mar 17, 2018
    …or controlling it
    This should allow tests to throw assertions from *within* the EDT and have
    them cause a test failure.
  6. AsynchronousUploadPrimitivesTaskTest: convert to use of JOptionPaneSi…

    risicle committed Mar 18, 2018
    won't yet have an effect until internal isHeadless() checks are removed
  7. ExportProfileActionTest: convert to use of JOSMTestRules & JOptionPan…

    risicle committed Mar 19, 2018
    won't yet have an effect until internal isHeadless() checks are removed
  8. PreferencesTableTest: convert to use of JOSMTestRules, ExtendedDialog…

    risicle committed Mar 19, 2018
    …Mocker & JOptionPaneSimpleMocker
    won't yet have an effect until some internal isHeadless() checks are removed
Commits on Jul 22, 2018
  1. remove some isHeadless checks which were preventing large amounts of …

    risicle committed Mar 30, 2018
    …code being run in some tests
  2. unit test headlessness: allow this to be set through an ant property

    risicle committed Mar 27, 2018
    update .travis.yml to use this to provide headless and non-headless builds
  3. tests: add PluginHandlerJOSMTooOldTest

    risicle committed Feb 24, 2018
    this test is a good example which exercises ExtendedDialogMocker and
  4. logging: add ReacquiringConsoleHandler, which should allow tests to c…

    risicle committed Mar 30, 2018
    …orrectly receive log output
    this integrates functionality previously used for the existing
    `ConsoleHandler`s in a hopefully-sane way
  5. PluginHandlerJOSMTooOldTest: add test documenting undesirable behavio…

    risicle committed Apr 26, 2018
    …ur around jar mismatch
  6. PluginPreferenceTest: add .platform() option to JOSMTestRules

    risicle committed Apr 27, 2018
    This omission was clearly masked by previous tests in the test run
    initializing this, when run alone it fails.
  7. JOSMTestRules preferences handling: clear defaultsMap between tests t…

    risicle committed May 7, 2018
    …o provide better isolation
    also add log message when skipping the setting of a value due to defaults -
    this hint could save a lot of debugging time if noticed.
  8. MainApplication$shutdown(): don't use isHeadless to detect test mode …

    risicle committed May 12, 2018
    …& skip shutdown calls
    instead mock out these shutdown methods in ExitActionTest, allowing the test
    to work similarly in both headless and non-headless modes
  9. ExtendedDialogMocker, HelpAwareOptionPaneMocker, JOptionPaneSimpleMoc…

    risicle committed Jun 9, 2018
    …ker: add invocations raising AssertionError to invocation log
  10. TMP skip MainApplicationTest#testSetupUIManager() on windows

    risicle committed Mar 31, 2018
    appveyor crasher
You can’t perform that action at this time.