Thanks!

On Sunday, February 10, 2013 10:17:55 PM UTC+2, Michael Pedersen wrote:
>
> Check out http://pythonpaste.org/deploy/#config-uris as there is a *huge* 
> amount of information there about the way that "use = config:' works.
>
>
> On Wed, Jan 16, 2013 at 12:27 PM, Moritz Schlarb 
> <[email protected]<javascript:>
> > wrote:
>
>> Just look at how it's done already for sqlalchemy.url?!
>>
>> Am Mittwoch, 16. Januar 2013 17:36:16 UTC+1 schrieb alonn:
>>
>>> could someone please shed more light about this issue? how can I 
>>> override some of development.ini imports (without loosing all of them)
>>>
>>> On Wednesday, January 16, 2013 4:43:03 PM UTC+2, Moritz Schlarb wrote:
>>>>
>>>> You should not replace that import line, I think!
>>>>
>>>> But when you use multiple database like this: http://turbogears.org/2.*
>>>> *1/docs/main/MultipleDatabases.**html<http://turbogears.org/2.1/docs/main/MultipleDatabases.html>,
>>>>  
>>>> you should of course use something like
>>>> sqlalchemy.first.url = sqlite:///:memory:
>>>> sqlalchemy.second.url = sqlite:///:memory:
>>>>
>>>> And I think it might be good to include that note about the test suite 
>>>> on that page, too!
>>>>
>>>> Am Mittwoch, 16. Januar 2013 13:36:30 UTC+1 schrieb alonn:
>>>>>
>>>>> Thanks Moritz. I found and inspected test.ini and found this line:
>>>>>     
>>>>>     use = config:development.ini
>>>>>
>>>>> If I understand correctly this means: take the configuration from 
>>>>> development.ini.  would the information from development.ini replace the 
>>>>> same variables in test.ini? And I should I remove this line when I 
>>>>> populate 
>>>>> test.ini with test configuration. or does it only add data not specified 
>>>>> in 
>>>>> test.ini
>>>>>
>>>>> On Wednesday, January 16, 2013 12:05:28 PM UTC+2, Moritz Schlarb wrote:
>>>>>>
>>>>>> The test suite should be using test.ini (which inherits from 
>>>>>> development.ini).
>>>>>> Maybe you take a look at the responsive files in a fresh quickstart!
>>>>>>
>>>>>> Due to your two-database setup, you surely need to use other 
>>>>>> sqlalchemy.url lines in the test.ini, I suspect that your application 
>>>>>> uses 
>>>>>> different config variable names and therefore just got the inherited 
>>>>>> values 
>>>>>> from development.ini.
>>>>>>
>>>>>> For testing, an sqlite database in memory is used because it is very 
>>>>>> much faster than a real db (and furthermore, the test suite should be 
>>>>>> independent of any infrastructure).
>>>>>>
>>>>>> Am Mittwoch, 16. Januar 2013 01:46:48 UTC+1 schrieb alonn:
>>>>>>>
>>>>>>> I decided to start learning how to do proper unittesting and using 
>>>>>>> nosetests. and I have some questions after encountering some very 
>>>>>>> annoying 
>>>>>>> problems.
>>>>>>> 1. state configuration: I've noticed when I'm not running nosetests 
>>>>>>> from the main project directory everything that depends on app state 
>>>>>>> (such 
>>>>>>> as information from the ini file) fails.  is this observation true? can 
>>>>>>> I 
>>>>>>> run nosetests with app state also for a specific test file without the 
>>>>>>> whole testing suite? 
>>>>>>>
>>>>>>> 2. app state and configuration: what ini file does nosetest refer 
>>>>>>> to? development.in, production.ini? other?
>>>>>>>
>>>>>>> 3. I'm using a 2 db configuration: the app inner setting are in a 
>>>>>>> mysql/sqlite db and it works also with a mssql server (I have write 
>>>>>>> permissions, but this the DB of another app = I can't temper with the 
>>>>>>> tables no matter what), also the sqlalchemy in the app works with the 
>>>>>>> dual-db configuration (after a short battle) the tests do not. I need 
>>>>>>> the 
>>>>>>> db not to be erased after the testing  (which just happened to 
>>>>>>> me, fortunately enpugh. and by mistake,  only in the app inner db and 
>>>>>>> not 
>>>>>>> in the main mssql db)
>>>>>>>
>>>>>>>
>>>>>>> be glad with any help with thi
>>>>>>>
>>>>>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "TurboGears" group.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msg/turbogears/-/k6yqMfPHAxEJ.
>>
>> To post to this group, send email to [email protected]<javascript:>
>> .
>> To unsubscribe from this group, send email to 
>> [email protected] <javascript:>.
>> For more options, visit this group at 
>> http://groups.google.com/group/turbogears?hl=en.
>>
>
>
>
> -- 
> Michael J. Pedersen
> My Online Resume: http://www.icelus.org/ -- Google+ 
> http://plus.ly/pedersen
> Google Talk: [email protected] <javascript:> -- Twitter: pedersentg
>  

-- 
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/turbogears?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to