In Sublime Text 3 PHP Unit doesn't work. Bundle has installed correctly but plugin is inactive. Has anyone resolved the problem?
Thanks in advance.
I strongly suggest you to use this package which isn't available on Package Control:
Sublime-PHPUnit
You need to pull this in manually by navigating to ~/Library/Application Support/Sublime Text 3/Packages and paste it in. If you setup a few key binding, the workflow is very snappy. Watch this video for more info:
Instant PHPUnit Feedback and Workflow
At the time of writing, there is a working ST3 version in the develop branch:
https://github.com/stuartherbert/sublime-phpunit/tree/develop
I got it to work by cloning the develop branch into my {ST3}/Packages folder and then restarting ST3.
At the time when I installed the plugin (a couple of months ago), the ST3 compatible version of sublime-phpunit was not available through Package Control, which is why I installed it with git.
Hope this helps!
Try PHPUnitKit, a Sublime Text plugin for running tests on different granularities. It's available on Package Control!
FEATURES
Run Test File
Run Test Suite
Run Nearest Test
Run Last Test
Fully customisable configuration
Supports Composer installed PHPUnit
Supports colour results, diffs, errors, etc.
Jump to next and jump to previous failure
Related
I'm watching a video about Unit-testing. An author of that video uses very convenient interface of PhpStorm that shows details of testing.
But I don't have this. I have a simple, not pleasant interface))
The year of the video is 2015. My version of PhpStorm - 2018.3 (I think it's much newer)
Why should I do to make interface of my PhpStorm like on the first picture? Do I need to install some plugin?
If it helps: I use it with Yii2.
Problem was that in
Settings > Languages & Frameworks > PHP > PHPUnit
I have chosen the option to use Composer autoload to load PHPUnit. And Path to script I have put /vendor/bin/phpunit.
When I set /vendor/autoload.php it started work as expected
The only problem is I was forced to update PhpStorm to 2021. Only when I updated it and click "Run test" it showed me the message
Test framework quit unexpectedly
I google it and found the answer. Why didn't PhpStorm 2018 show me the message - I don't know.
I work for a shop that has standardized on TFS. We have one project that was developed by a subcontractor in php. You can't even load this thing in Visual Studio.
I managed to create a repo for the project, but I need to find out how to check the project in. Is there some other app (like tortoiseSVN) that I can use to check stuff in and out without Visual Studio? Or is there some way to get VS to load the project and check it in and out without creating a .sln, .csproj, or any other unwanted files?
Actually, it's totally possible to use Visual Studio to do this.
You can use the web interface to create a repo...
You can't edit the php in Visual Studio of course, but you can open the Source Control Explorer to check the project into the repo.
You need to remember to go in Visual Studio to check files out before you edit them, and then check them back in when you're done.
It's clunky, but not as clunky as buying a $200 per year setup we're only going to use a few days out of the year. We're a Microsoft shop after all.
I'm assuming you're using TFVC and not Git for version control.
If you don't have Visual Studio at all, you can install Team Explorer. If you already have Visual Studio installed, that's fine too.
The tool you're looking for is tf.exe -- it's the command line tool for interacting with TFVC.
You can also consider using a Git repo instead of TFVC for this -- although TFVC can be used for any type of source code, it has a reputation of being exclusively for Visual Studio-based projects. Git is likely to be more familiar to folks who have never worked with TFS or TFVC and have not spent much time using Visual Studio.
You can use PhpStorm, then install the TFS Integrartion plugin for it, then you can manage the php projects in PhpStorm same as manage projects in VS.
Just follow the steps mentioned in below screenshot to configure the PhpStorm:
More information you can refer to Using TFS Integration.
im very frustrated because i lost a lot of hours reading and testing, and could not find how to make it live.
I cloned and downloaded Zidisha git
Then i followed these instruction: image
At the stage 5. -vagrant up calls a file that doesn't have on the server.
I need to find a server with this saucy.box or exists a easier/another method?
Thank you
This project is using ubuntu-saucy which has been deprecated (see https://en.wikipedia.org/wiki/Ubuntu_version_history#Table_of_versions) so the link referenced on cloud-images is not available anymore, and the box itself (larryli/saucy64) is not available on vagrant atlas.
You are left with 2 options:
build your vagrant box yourself using the same ubuntu release (can be found https://cloud-images.ubuntu.com/releases/13.10/)
upgrade the ubuntu release to a more recent one and still supported (you can use trusty64 or xenial64)
Note: this project has not been updated for the last 3 years - there are many chances that you will find a lot of obsolete things in it.
I'm still new to coding and I'm learning everything on my own. This is a silly question for you but after reading a dozen of articles I am still confused.
I have a php based website on a shared host. After reading the various articles on benefits of using repositories and Composer, I decided to give it a try. These are my difficulties so far:
Which version of the operating system of Composer should I download, to enable me to install/update repositories of my cPanel based shared hosting?
If I am to install Windows version, how do I connect to my shared hosting to install/update the repositories?
My apologies for my silly questions, but it would really help.
If you are using shared hosting, you are unlikely to be able to use Composer on the host itself. Furthermore, you are not encouraged to use Composer "on production".
I would recommend you use Composer locally (on the O/S of your local machine), to compose your project and install your dependent packages. Once it's all working and tested with your own code, you upload your entire development directory tree including the resulting vendor library - as one big FTP/SCP upload of "flat files".
Once you get more advanced you could adventure into automated deployment techniques, but I feel for now you would be best to stick to using Composer as a local development tool to manage your codebase.
Update, further details:
Composer is really a tool to help you manage your codebase in development. It's not intended as a "deployment" tool. Previously you used to find a library you liked, download it, unzip it into your codebase somewhere random like "lib/stuff" and then link to it, and commit it into your version control system (VCS). OK, but they a year later you want to update it and you have to download it again, figure out where you saved it and how to overwrite the files, or delete old ones... it gets hard. Also your VCS repository gets full of 3rd-party components - even duplicates of the same one! Composer solved this by bringing order to this long-term dependency management chaos.
The reason you don't want to run Composer "on production" (i.e. your live website), is that during the process of download, update, composition your website will probably be broken. Even if the composer process works, this could be several minutes of broken site. After the update has finished - you now have a completely new set of 3rd party packages: how do you know they are compatible with your codebase?
So therefore you only do composer updates locally, test everything, amend your code to work the shiny new updates, and only then do you decide to upload the whole new site to the server - just as if you'd cobbled it all together manually. The deployment is independent.
I have recently upgraded to net-beans 7.4 (PHP). Afterwards I have edited a php file and tried to create a patch as we generally do in net-beans Team > Export Diff Path & Tools Drop-down as well. However I am not able to find any option there. I have attached for where I am looking for.
Is there any way to create patch on net-beans 7.4
That would only happen if somehow your sources aren't recognized by NetBeans as managed by Git (or any source control).
Export Diff Patch is clearly listed in Git support specification for NetBeans 7.4.
However, it is invoked a bit differently:
Select the project root node in "Projects" view and invoke Team | Patches | Export Uncommitted Changes... main menu action.
"Export Diff Patch" dialog shows up.
Make sure you have the mlatest version of the Git plugin in your latest NetBeans.