Unittesting settings

Hello.
I tried use unittest module for my perl project and has faced with an issue - I could not find where I can assign additional folders with libs.
In Komodo global setting and in project options on tab ‘language’->Perl I have added custom folder, as say ‘/home/shura/perl5/lib/perl5’, but unittest module does not use it.
Moreover, I have assigned environment variable $PERL5LIB=/home/shura/perl5/lib/perl5 and it has not helped.
Also Unittest dialog window does not allow change command editbox, it’s readonly.

How to add custom lib directories?

Morning @Alexander_Zaitsev,

This should work I believe. Where did you set this?

This has caught others off guard. You need to select Custom in the Framework field above.

  • Carey

Environment variables are added in my .zshrc and also I’ve tried to add it to Settings -> Environment.

Thanks, I’ll try

Morning @Alexander_Zaitsev,

I assume you then start Komodo from a terminal session? If you’ve set it in .zshrc then start Komodo from a terminal, you should see any env vars set in the terminal session also in Komodos Preferences > Environment. Did you not see PERL5LIB there?

Could you confirm that you can run the code you expect to run, in a terminal? A simple use Something::I::Expect::To::Be::There; should suffice. Run that in a terminal, confirming it runs. Then start Komodo and try to run the Debugger on the same file.

I want to try and narrow things down to what’s going on.

  • Carey

thank you for your help.

It was my fault, as I wrote I added environment variable in project settings

$PERL5LIB=/home/shura/perl5/lib/perl5

Dollar was not needed there, I removed it and now everything works well.

But just a note. Before I do that, everything except unittesting worked well, I could run my program in terminal, I could run it in debugger. Syntax checking worked well too.

Seems like unittesting (prove) does not get settings from Project Preferences → Languages → Perl → Additional Perl import directories.

Oh this sounds familiar now. Can you share which version of Komodo you’re on? Help > About Komodo

I fixed a bug a month or so ago where some sub process were launching with over written environments (rather than augmented). If you use Komodo 12 nightly you may not need to set PERL5LIB.

  • Carey

Komodo IDE, version 12.0.0, build 91824, platform linux-x86_64.
Built on Tue Jan 14 11:42:53 2020.

Thanks @Alexander_Zaitsev, that fix should have been in there. I guess it’s not that.

Did you happen to update to the nightly I shared? If yes, was there a difference?

Ok, I’ve tried to install nightly
Komodo-IDE-12.0.1-91852-linux-x86_64]$ ./install.sh
Enter directory in which to install Komodo. Leave blank and
press ‘Enter’ to use the default [~/Komodo-IDE-12].
Install directory:

‘~/Komodo-IDE-12’ already exists. Installing over an existing
Komodo installation may have unexpected results. Are you
sure you would like to proceed with the installation?
Proceed? [y/N] y

install: error: [Errno 17] File exists: ‘/home/shura/Komodo-IDE-12/lib’

I do not want setup the IDE again.

We don’t keep preference settings in the Install Directory. That would be a big nono. All your prefs are in ~/.komodoide. You can safely delete Komodo-IDE-12 and install the nightly.

FYI, once 12.0.1 is release you’ll be automatically prompted to update to it, as well any new nightlies we release.

  • Carey

Ok, I’ve installed 12.0.1 and nothing changed. Unittests do not work without additional environment variable PERL5LIB=/home/shura/perl5/lib/perl5