0

this might be a simple question but i could not find a way out through this , wanted some help

I have 3 common libraries in one project and a testing project( Module wise here we are testing hardware so modules differ from time to time but interaction libraries are same ) i wanted to add a variable which can be used across the libraries and this testing project.

Example :

i have

Testing Project -> Library1-> library2 -> library3 -> Hardware

response will be sent from hardware

one of the requirement that i have got is to define common variable in solution and use it across the libraries and testing project

i have tried to define app config but it is limited to one library and cannot be used in the other library

John Saunders
  • 160,644
  • 26
  • 247
  • 397
ansar
  • 128
  • 13
  • possible duplicate of [Can a unit test project load the target application's app.config file?](http://stackoverflow.com/questions/344069/can-a-unit-test-project-load-the-target-applications-app-config-file) - this might be the answer to your question. – t3chb0t Dec 30 '14 at 06:32
  • @t3chb0t hi , thanks for the post , but i do not have .testrunconfig and we are testing based on the framework developed by our team . so the point i was looking for is to have a sort of global variable to access across the solution – ansar Dec 30 '14 at 06:38

1 Answers1

1

I was thinking about a solution that can be accessed across the solution, app.config has not worked for me initially but after copying the same into bin folder i was able to access that variable across the solution.

@t3chb0t Thanks for the link , sorry for the late reply as i was on vacation

ansar
  • 128
  • 13