473,404 Members | 2,137 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

NUnit web.config ASP.NET?

Hi!

When running NUnit tests against my ASP.NET application I want the values in
the web.config to be loaded, otherwise connectionstrings and other
configurations won't be availible and the tests will fail.

How do I load the web.config from the NUnit tests?

/Erik
Nov 18 '05 #1
2 2039
The name of the configuration file used by default can be
found on the Properties page for the NUnit project. Be
aware that a project is not created if all you do is open
a DLL through NUnit. Instead, start with a New|Project
and then load up the test fixture.

Hope this helps.

Bruce Johnson
http://www.ObjectSharp.com/Bruce
-----Original Message-----
Hi!

When running NUnit tests against my ASP.NET application I want the values inthe web.config to be loaded, otherwise connectionstrings and otherconfigurations won't be availible and the tests will fail.
How do I load the web.config from the NUnit tests?

/Erik
.

Nov 18 '05 #2
Great! tnx!
"Bruce Johnson" <Br***@ObjectSharp.removethis.com> wrote in message
news:00****************************@phx.gbl...
The name of the configuration file used by default can be
found on the Properties page for the NUnit project. Be
aware that a project is not created if all you do is open
a DLL through NUnit. Instead, start with a New|Project
and then load up the test fixture.

Hope this helps.

Bruce Johnson
http://www.ObjectSharp.com/Bruce
-----Original Message-----
Hi!

When running NUnit tests against my ASP.NET application

I want the values in
the web.config to be loaded, otherwise connectionstrings

and other
configurations won't be availible and the tests will

fail.

How do I load the web.config from the NUnit tests?

/Erik
.

Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Klas Mellbourn | last post by:
I have several assemblies, in separate dll:s, each with nunit tests embedded. Every assembly requires its own config file. I would like to run all nunit tests on the same command line. Like this: ...
0
by: Mike | last post by:
I found this message posted from last year: I'm using NUnit to test my assembly. When my assembly runs (.exe) normally it uses it's .config file, but when I test my assembly using NUnit it...
1
by: Peter Rilling | last post by:
When running my unit tests for our web project, I am having a difficult time getting values from the config file. When running from the web server, the config file is able to be read from the...
6
by: tchaiket | last post by:
Hey all, I'm using NUNIT to test our classes. However, I don't want to hard code test data into the NUNIT classes. For example, to test adding a new Client, I don't want to hard code the...
1
by: Gonza | last post by:
Hi group, i'm trying to create tests for my solution, so i have a project with nunit tests. I'm using the data application block as my data access layer, and the problem i'm having is that when i...
1
by: nyathancha | last post by:
Hi, I am using WSE to implement security using x509 certificates. This works when I use a windows client but throws an exception when I use NUnit. My Code looks as follows : UsernameToken...
2
by: chris | last post by:
I have created a file, called nunit_project_name.dll.config, within the bin folder of my Nunit project, but Nunit is not able to find the file. Is this is the right location? I can access the...
1
by: skneife | last post by:
Hi! When running NUnit tests against my ASP.NET application I want the values in the web.config to be loaded, otherwise connectionstrings and other configurations won't be availible and the...
2
by: Mark Elliott | last post by:
Hi All, I'm just playing with asp.net mvc and link-to-sql for the first time. I'm using visual web developer 2008. I create the project fine, choose nunit as my test framework in the wizard. ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.