SuggestedStories
This page had been hijacked by wiki-spammers. I rolled back this page to the most recent version that contained non-spam posts, and deleted the irrelevant stuff. Randolph Peters?



Suggested Refactorings to Add To Refactor Page



An HTML element ID for the fit.Summary table

I am trying to use Ant to run FitNesse tests in a headless manner. I am using HTMLUnit to run my suite and I want to verify that the "total count" of the suite shows 0 wrong, 0 ignored, 0 exceptions. It is much easier to locate an element of an HTML page if it has an ID (the id attribute).


Command line switch to turn on the Updater

I don't want the Updater to run unless I explicitly ask it to run, which I would do each time I update my FitNesse code base. So I want a command line switch which would cause it to run on startup. I don't care if the server stays up, or just prints a "succeeded" message and exits.


Looping Action Fixture

MM> LoopingActionFixture?.... It sounds like a cool idea. Its definately
MM> worth coding up and giving it a try.
I suspect you could do it something like this.. override doRows and
make 'current row' an instance variable. Add two commands "do" and
"while". Whenever you hit a "do" push the currentRow.more on a stack.
Whenever you hit "while" evaluate its condition. If true, then make
currentRow point to the top Parse on the stack, and go on. If false,
then pop the stack and go on.


Test Container

I've created a class I call TextContext? which my SetUp page instantiates. This context contains all my page-level testing globals, such as a connection to my server that I'm testing. I'd like to have the ability for objects to be available down through a suite of pages, so I can connect to my server, run a suite of tests, then disconnect - rather than connecting/disconnecting on each page.
Ideas include:
I like the idea of a test container - they could actually be JVM instances that are persistant, controlled by the FitNesse server via RMI or a socket protocol, and could receive commands from the server to run tests or suites. It would speed up launching tests, support suite-level object sharing, and running multiple tests in parallel.


Special Variables

A special variable like ${FITNESSE_ROOT} that contains the full pathname of the Fitnesse root directory. There are probably other such variables like FITNESSE_PORT. It might also be a good idea to find a way to access environment variables. Perhaps a syntax like this $${environment_variable}

'We do this at PrintSoft? by putting (by hand) "!define FITNESSE_ROOT {this is my directory}" in the content.txt file in the FitNesse root directory'


- .KenHorn


Date format problem

found in brazil when trying to rename a page.
!|java.text.ParseException: Unparseable date: "Mon, 09 Jun 2003 15:23:34 GMT"|
|        at java.text.DateFormat.parse(Unknown Source)|
|        at fitnesse.responders.FileResponder.setNotModifiedHeader(Unknown Source)|
|        at fitnesse.responders.FileResponder.prepareFileResponse(Unknown Source)|
|        at fitnesse.responders.FileResponder.makeResponse(Unknown Source)|
|        at fitnesse.FitnesseServer.makeResponse(Unknown Source)|
|        at fitnesse.FitnesseServer.serve(Unknown Source)|
|        at fitnesse.socketservice.SocketService$ServerRunner.run(Unknown Source)|
|        at java.lang.Thread.run(Unknown Source)|
|
|
Same error when running on a Korean winxp machine (on cygwin or on cmd). It hasn't occured in Internet Explorer but in Firefox it occurs everytime. There seems to be some problem with the date encoding/locale in If-Modified-Since and Last-Modified pair.

Just found the reason for this: In src/fitnesse/http/Response.java, makeStandardHttpDateFormat() the SimpleDateFormat? is instantiated using the default locale, so this works nice in the US but not in the rest of the world. Easy to fix, just add Locale.US in the ctor call of SimpleDateFormat?.

Fixture/Package path. It would be nice to be able to say FoobarFixture?, and have

the code look through a list of packages for that, so the non-techinical author doesn't
have to write com.company.department.project.appliation.fixtures.FoobarFixture? and such all the
time It will make the test more readable, too.
DavidCorbin?


Standard Out needs to be "formatted" as text

If a Fixture (or an application) generates output on StdOut, it shows up at the top of the test page. However, newlines
are lost. The output should be converted to HTML (at least convert newlines to <BR>
DavidCorbin?
(Enclosing the output in <pre> ... </pre> could be a simple starting point...)
J. Siekmeyer


Support debugging

It is easy to debug your tests using the FileRunner? from FIT. But you the tests in HTML and not the internet WIKI format of Fitnesse. The following code is a sketch of the solution:
public class CostumizedFitnesseRunner
{
!|private static final String TEARDOWN = "TearDown";|
|private static final String SETUP = "SetUp";|
|private static final String TMP_SRC_FILE_PREFIX = "FitnesseTest_";|
|private static final String HTML_EXTENSION = ".html";|
|private static final String RESULT_PREFIX = "Result_";|
!|public static void main(String[] args)|
|{|
||String path = null;|
||String testName = null;|
!||if (args.length != 2)|
||{|
|||System.out.println("Usage: java fitnesse.debug.CostumizedFitnesseRunner <path> <testname>");|
||}|
||else|
||{|
|||path = args[0];|
|||testName = args[1];|
!|||try|
|||{|
||||WikiPage wikiPage = FileSystemPage.makeRoot(path, testName);|
||||HtmlWikiPage htmlWikiPage = new HtmlWikiPage(wikiPage.getData());|
||||String html = htmlWikiPage.testableHtml();|
!||||if (html.length() == 0) {|
|||||System.out.println("Wiki page not found: " + path + "/" + testName);|
|||||System.exit(-1);|
||||}|
!||||WikiPage setUpPage = FileSystemPage.makeRoot(path, SETUP);|
||||String setUpHtml = new HtmlWikiPage(setUpPage.getData()).testableHtml();|
!||||WikiPage tearDownPage = FileSystemPage.makeRoot(path, TEARDOWN);|
||||String tearDownHtml = new HtmlWikiPage(tearDownPage.getData()).testableHtml();|
!||||File tmpSrcFile = File.createTempFile(TMP_SRC_FILE_PREFIX, HTML_EXTENSION);|
||||String tmpDstFileName = RESULT_PREFIX + tmpSrcFile.getName();|
||||FileOutputStream fos = new FileOutputStream(tmpSrcFile);|
||||PrintStream ps = new PrintStream(fos);|
||||ps.print(setUpHtml);|
||||ps.print(html);|
||||ps.print(tearDownHtml);|
||||fos.close();|
!||||FileRunner runner = new FileRunner();|
!||||runner.run(new String[] { tmpSrcFile.getAbsolutePath(), tmpDstFileName });|
|||}|
|||catch (Exception e)|
|||{|
||||e.printStackTrace();|
|||}|
||}|
|}|
}

The handling of SetUp and TearDown? pages isn't really correct since a possible hierarchy isn't handled.
StefanRoock, email: stefanATstefanroockDOTde


HTML dump of Fitnesse-WIKI

Integrate a function into fitnesse to generate a html dump of the wiki pages in Fitnesse. These pages can then be versioned with CVS.
This function sould be easy to implement based on the previous story suggestion ("Support debugging")
StefanRoock, email: stefanATstefanroockDOTde


Access to local files

Possibility to use internal links such as file://C:/etc
----


Widget to sum up a column in a table.

Currently we are using fitnesse to track our milestones and iterations, each iteration we remove the user stories from the milestone and have to re add the total story points remaining.

For example:

User Story Estimate
add !sum widget 2311
yet more work 1
total !sum (would show total here, because the programmer is too lazy to add)
Thanks!
MarkEnsign?


Return Additional Metrics Data

We are considering using FitNesse for our test suites, however we need a way of additionally displaying test metrics (number of pages printed, number of images ripped, pages generated per minute, ...). Some of these metrics are like additional test checks i.e. number of pages printed, others need to be plotted over time i.e. pages generated per minute.
e.g.
  a b c produce() =pages =imgs =ppm
  testdoc 600dpi PDF true 6000 6000 #
Even a pointer on how to code it ourselves could be helpful.
Thanks,
keithDOTadeneyATprintsoftDOTde
Hey looking at ResponseExaminer.java I found out how to do this! It was obvious really. The table looks like
  a b c produce() pages() imgs() ppm()
  testdoc 600dpi PDF true 6000 6000  
where produce() does the test, and pages()/imgs()/ppm() just return cached test results.
Great tool thanks,
Keith


Graceful Getters

Most of our objects use getters. It would be nice if FitNesse could drop the gets out on the row and column fixtures, so I could say "account balance?" instead of "get account balance?"


Smart !fixture directive

The !fixture directive should be aware of the !path directives in force for at least the page it appears on. This would allow for simpler !fixture specifications. It would be even nicer if it were aware of those in affect on the page it was being used on (i.e. in the drop-down list). The significance of this last statement is if a classpath element that contains a fixture is added on a sub-wiki then the fixture name could potentially be shortened when editting that sub-wiki page.


Secure the new Shutdown feature

-The new orderly shutdown feature is a security hole and needs to have password protection added. As a convenience feature on my local Fitnesse server I have added a table that is comprised of a single cell that contains the shutdown URL labled as "Shutdown FitNesse Server" to the top level PageHeader. Clicking this "button" on any page shuts down the server as desired. Sweet. The problem is I could add the same information to any public FitNesse server (i.e. this one or butunclebob.com) and then anybody could easily shutdown the server for the entire world (assuming you're using the latest jar). Of course nobody has to have modification permissions to shutdown a FitNesse server. All it really takes is crafting the correct URL in your browser and the server goes down! Password protection would help prevent this.- Withdrawn. This feature is already secured. I had failed to recognize this as I was always operating logged into my server whenever I exercised my button.


Restore Properties property to pages such as /PageHeader in the distribution.

-It is annoying to have to manually edit the XML properties file to restore this feature so that modifications such as that described in the preceding item may be made.- Withdrawn after reading the Properties bullet on .FitNesse.MarkupPageAttributes
-

Searching

  • Search to support searching in subpages only instead of whole Wiki
  • Search not to miss words. In the test case, I have now like 500 words in subpages in a format like this:
|word| definition|
when searching certain words are found, and certain word on the very same page are simply not found.
-

Variable names with punctuation

It would be nice if variable names would support punctuation. Especially since Java System properties are implicitly defined as variables and they all use a period for separating words. Currently how would you access a System property like user.dir? I can't do something like !path ${user.dir} currently.


-JjL
-

Arbitrary variable assignment within tables

It would be nice to be able to assign a variable in any table cell that could then be used in any other, regardless of the fixtures used. Syntactically, this could use ${VAR_NAME}= to assign whatever value would normally be rendered in that cell to that variable. For instance:

some_fixture
get_value ${VAR_NAME}=
--

Server side scripting languages

Would it be hard to use a page on a server as a fixture? FitNesse would then just call a server-side script (in PHP, ASP, ...) and gets the answer from that call. This would enable FitNesse to work with all web server scripts in any language. - WillemBogaerts?.



[.FrontPage] [.RecentChanges]
Last modified anonymously on May 20, 2008 at 10:10:04 AM