summaryrefslogtreecommitdiffstats
path: root/ui-desktop/src/test/java/market
Commit message (Collapse)AuthorAgeFilesLines
* tests: cover the ex-2 loader, order book trading and desktop stateHEAD2.0masterKostya11 days4-0/+630
| | | | | | | | | | | | | | | | | | | | | | | | | Add tests for the behaviour introduced in the last few commits, so later changes to matching, settlement or the UI state can't quietly break it. On the service side, Ex2LoaderTest loads the ex-2 fixtures and checks that every invalid file is rejected for its own reason, including events with no market maker or two of them, and v1 files. The order book tests cover buys and sells that match or rest in the ladder, self-trade prevention, cash and shares reserved by resting orders, price bounds, risk rejections, and resolution cancelling resting orders and paying the holders. A simulation checks that LMSR settlement conserves money. LedgerMapperTest used to pin the unmapped seq and at fields to their defaults. Now that the mapper fills them from the entry id and time, assert the real values and add a case for a null time. On the desktop side, AppStateTest drives the real ServiceEngine through loading, event creation, LMSR and order book trading, and checks that the observable state updates. Smaller tests check chart timestamps, money and probability formatting, and that every animation settles on its final frame, which is what the UI shows when animations are off.
* flatten modules to repo root, vendor deps, repair Eclipse build pathsKostya2026-08-091-0/+12
Move api, engine, ui-console and ui-desktop out of modules/ up to the repo root and drop the empty exception project (GuessMarketException now lives in api). Vendor gson, jaxb, okhttp, openjfx and tomcat under lib/, and group the JUnit standalone jar into lib/junit/ alongside them. Rewrite every .classpath: drop the copy-pasted optional="true" that was masking real build path errors, point the library entries at ../lib/, and put the JUnit jar on the test source folders so the placeholder AppTest classes compile. ui-desktop: take the JavaFX jars off the modulepath (there is no module-info.java, so module="true" left the packages unresolvable) and add a Launcher that calls Application.launch, avoiding the "JavaFX runtime components are missing" check without VM arguments. engine: add LocalGuessMarketService and the GuessMarketContext provider interface, and give GuessMarketException the no-arg and cause constructors they need.