Questions tagged [ecomdev-phpunit]

7 questions
5
votes
2 answers

EcomDev Phpunit tests called twice during execution

I am trying to run few unit test cases and I see that they are being run twice in each run, I am not sure of the reason though. The following is my test case structure - class Sample_Module_Test_Model_HelloserviceTest extends…
g0c00l.g33k
  • 2,458
  • 2
  • 31
  • 41
1
vote
0 answers

How to skip internal calling function in PHPUnit test?

I have a class Receipt.php that I need to PHPUnit test. pending(); …
Siddhartha
  • 31
  • 4
1
vote
1 answer

symfony3+PHPUnit form test issue

form test return error Tests\AppBundle\Form\Type\UserPreferencesTypeTest::testUserPreferencesForm Symfony\Component\OptionsResolver\Exception\UndefinedOptionsException: The option "constraints" does not exist. Defined options are: "action",…
majid hussain
  • 31
  • 1
  • 5
1
vote
0 answers

How to mock custom block in Magento ecomdev test case

I'm trying to test my block method with magento ecomdev phpunit. I have block like this: I'm trying to…
1
vote
1 answer

ecomdev phpunit fixture for website specific configuration

I'm trying to understand PHPUNIT + MAGENTO and I found this extension https://github.com/EcomDev/EcomDev_PHPUnit which seems to be great tool. I want have a fixture which set shipping method 'Freeshipping' per website. I found a solution for default…
Jaro
  • 3,799
  • 5
  • 31
  • 47
0
votes
1 answer

Getting 'LogicException: No such property: session' when i run phpunit test case in command prompt

I was trying to run a phpunit test case of a controller. but am getting saying that 1) DefinerControllerTestCase::test_insertImageDetails LogicException: No such property:…
Praveen sivadasan
  • 165
  • 1
  • 2
  • 16
0
votes
1 answer

getting an error "Trying to get property of non-object" in phpunit 5.4

I am trying to execute the following script in linux(centos 6.6) command prompt, but i am getting an error Trying to get property of non-object. I am using php version 5.6 and phpunit 5.4. This is the source file .... protected function…