Vinayak, I don't think it's appropriate to request other developers to help you fix your unit test. I think both myself and Daniel explained that you need to use the preprocessor variable in your .cc unit tests. If you have problems getting it right, then it should be trivial to debug: you just check what you write as a path within your .cc file and compare that to your directory structure. Do you point to the file which exists? Is it the right file? You can also run tests in verbose mode to help with this task: ctest -V -R "some/regex" "Setting up testsuite in user projects" https://www.dealii.org/developer/index.html gives code snippets and explains how to setup a user project into a library+executable.
Note that everyone here in the forum helps others voluntarily. So it's a place to ask questions and seek for advice, but the place to ask others to solve your task for you. Also make sure you read this guidelines post: https://groups.google.com/forum/?fromgroups#!topic/dealii/GRZMUTLIm2I Regards, Denis. On Thursday, October 12, 2017 at 12:13:11 PM UTC+2, Vinayak Gholap wrote: > > Hello Daniel, > > I have attached the test.cc (in my case gaussian-charges.cc) , .prm and > .data input files. With this setup for test it fails. > > Could you help? > > Regards, > Vinayak Gholap > > On Friday, October 6, 2017 at 5:34:56 PM UTC+2, Daniel Arndt wrote: >> >> Vinayak, >> >> Your error looks like you are trying to call read_input on your data file >>>> instead of the parameter file. >>>> At least you seem to be able to find the correct path to your data file >>>> in the unit test and this is what this thread >>>> is about, isn't it? >>>> >>>> I tried to parse the .prm file but still the unit test fail. And yes I >>> am able to find the correct path to my data file but not able to run unit >>> test with it. >>> >> So again: Are you calling read_input for the parameter file or the data >> file? How does your setup actually look like? >> Is it similar to the one I suggested above? >> >> >>> >>> Do you have a working setting (without the testsuite setup) for which >>>> you can treat your data file appropriately? >>>> If this works, we can try to find out why it doesn't work using the >>>> testuite setting. >>>> >>> >>> Yes I have a working setting where I am able to read different data >>> files for different .prm files and they work as expected for all. >>> >> Then, the code should be identical apart from putting SOURCE_DIR in the >> places where you are reading the parameter file and the data file. >> Is this the case? >> >> If this doesn't help, can you come up with a minimal example version of >> the setup you are using? >> >> Best, >> Daniel >> >>> >> -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.