Closed stela closed 8 years ago
Thanks! I'll dig into it.
I fiddled a little with content.txt pages in IntelliJ IC 16 EAP (with the latest FitNesse plugin installed), but I can not reproduce the error so far.
Is it a specific page (or specific content) that caused the problem? Can you share your page content? Are there any actions I should perform to trigger this exception?
Our fitnesse scripts are fairly complex with lots of includes and such, so not easy to make a minimal sample which reproduces it. It does look like it gets stuck on one or two scripts all the time, might well be due to contents and not by random ordering then if you can't easily reproduce it. It's for work so can't share the whole project.
The content parsing is my prime suspect. I'm using FitNesse's native parser to process the pages, so it may turn out that there is something going wrong there.
You can also send the page directly to me if you do not feel like posting the content here (gaphor@gmail.com).
OK, could simply be that the page is broken syntactically without me realizing it... If so, wouldn't it be better to mark the broken parts of the page red, marking it with an error message and catching the exception?
If for some reason a part of the page is invalid, the parser should treat it as plain text. That's how the wiki parser does its rendering. More complex elements, such as !include statement, need to figure out their offset themselves, which might result in offset differences. IIRC the highlighter wants regions to be connected. In IJ 16, the parser might have become more picky.
Can I close this issue? I think version 1.4.4 has some improvement that should make those errors less likely.
Looks like this issue is resolved with 1.4.4 :-)
I still got a lot of "java.lang.IllegalStateException: Unexpected termination offset for lexer fitnesse..." when opening the fitnesse project and selecting "File - Invalidate Caches/Restart" when using version 1.4.3. I updated the fitnesse plugin to version 1.4.4 and now the errors are gone, thanks.
(now though, all fitnesse scripts seem to claim "No fixture method found" or "No fixture class found", but it's an improvement at least)
Are your fixtures in Java? That's currently the only language the FitNesse plugin can deal with.
Yes, they are all Java. They are included via the pom.xml from a separate project. IntelliJ itself can find open them from the Fitnesse project.
Indeed. The current search scope is limited to source, test and module dependencies. Libraries are not included in the search. Before I can broaden the scope to libraries, the plugin needs to handle import paths properly, so a lookup results in less false positives.
Having that said, would it make sense to join the FitNesse module with the fixtures? I think it would make sense to have high-level/businessy fixtures and (for example) drop scenario tables altogether. It greatly improves maintainability.
Got this exception when loading a fitnesse project using IntelliJ 16 EAP. The filename reported changes occasionally (maybe the order they are processed is a bit random?). I didn't manage to trigger it using IntelliJ 15.