RE: [Pydev-users] Importing an Existing Package into PyDev
Brought to you by:
fabioz
From: Carroll, B. <Bar...@ps...> - 2006-04-26 00:32:33
|
Fabio: Again, thank you for your help. =20 Okay. I have managed to set up the symgen project and added '/symgen' to = the project. I had to move the encode folder from its location under = J:\My Documents/python to J:\My Documents\Projects\symgen, as PyDev = could not traverse the shortcut to access the files. No matter. I can = now open the project, open the various source files, create new folders = under the project, and do other file management tasks.=20 Next, I tried to create a new package to hold my test case files. I = selected 'PyDev Package' from the 'New' pull-down menu. The instruction = in the dialog box was "Create a new Python module", which confused me. = I decided to enter the name of my desired package: 'encodetests'. = Clicking on 'Finish' resulted in a new folder with my package name, = containing an empty __init__.py file. I added a descriptive comment to = the __init__.py file and moved my test case files into the folder. =20 So far, so good. =20 Next I tried running my test cases from within the work space. I = highlighted my top level test file, 'encodetests.py', opened the pop-up = menu and selected 'Run As/Python unit-test'. Lo and behold, the test = ran, the console window showed the result, the one failing test case = failed as expected and the link to the failing line of code was = highlighted. =20 Happy day! I' up and running! Thank you Again, Fabio, for your help. I'm sure I will have lots of = additional questions. =20 Regards, =A0 Barry bar...@ps... 541-302-1107 ________________________ We who cut mere stones must always be envisioning cathedrals. -Quarry worker's creed >________________________________________ >From: Fabio Zadrozny [mailto:fa...@gm...]=20 >Sent: Tuesday, April 25, 2006 3:19 PM >To: Carroll, Barry >Cc: pyd...@li... >Subject: Re: [Pydev-users] Importing an Existing Package into PyDev > >Hi Barry, > <<snip>> > >>The first issues I need to solve are: >> >>=A0=A0 1. Can I turn my symgen folder into a PyDev project folder, >>=A0=A0=A0=A0=A0=A0and if so, how? >> >Just create a new project and make the project location as=20 > >J:\My Documents\Projects\symgen >=A0 >(so you can use it as your source folder) > >>=A0=A0 2. Can I use my existing __init__ file as PyDev's __init__ = file, >>=A0=A0=A0=A0=A0=A0and, if so how? > >In the project properties, set the project root to be in the = pythonpath.=20 > >If that does not suit you, please report back.=20 > >Cheers, > >Fabio |