Where and How does Hudson/Jenkins store data?
Hudson/Jenkins doesn't quite work that way. It stores configurations and job information in /var/lib/jenkins
by default (if you're using the .deb package). If you want to setup persistence for a specific application, that's something you'll want to handle yourself - Hudson is a continuous integration server, not a test framework.
Check out the Wiki article on Continuous Integration for an overview of what to expect.
Jenkins can seem like it is storing data, based on what your scripts are doing and how.
As an example; the scripts that run your daily commit builds can be setup to hand off the "pass/fail" results to Jenkins to store in an XML file. Then, if you are ever interested in pulling up the historical "pass/fail" results and using them somewhere other than in the Jenkins GUI, you can make a call into the Jenkins API and get a return of that XML. Parse it and you've got the data you need.
But -- Other than doing this, Jenkins has no repository system all by its lonesome.
In addition, following is the jenkins api information: https://wiki.jenkins-ci.org/display/JENKINS/Remote+access+API
The answer is that jenkins will not set this up for you. You need to tell it how to setup the environment and how to execute it's tests. This is normally done in the build steps section. If you will provide more info as to which platform you are using them perhaps we could give you a more concrete answer. You could have a shell script that will install your application and run it's tests, and then you call that from hudson. Making the test runner output data in a hudson-friendly way to finally get the results of your tests into the webUI for viewing those.
It stores data in your home directory in a .jenkins
directory.
You can find all relevant information related to your builds in this directory.
Jenkins not provides build in support for connecting to any database.