Questions tagged [fixtures]

Fixtures are scopes used for running tests which isolate each test from global namespace pollution and side-effects from previous tests in order to avoid false positives and false negatives

1601 questions
0
votes
0 answers

DoctrineFixturesBundle symfony2 where to store fake images

I'm seeking for best practice, some logic solution where to store some fake files (images) for data fixtures, which I load with Vich Bundle. Now I'm storing fake image for posts in src/App/BlogBundle/Resources/public/images/fixtures But may be It…
0
votes
1 answer

How can I check a JSON array using RestFixture?

I have a JSON array like this: [ { "Id": 1, "Host": { "Id": 1, "LoginId": "abc" } }, { "Id": 2, "Host": { "Id": 3, "LoginId": "def" } …
Thaoden
  • 3,460
  • 3
  • 33
  • 45
0
votes
1 answer

Ember Error while processing route: index Assertion Failed: Unable to find fixtures for model

I have my index page where i show a list of invoices where the user can click to create and edit them, i am using DS.FixtureAdapter in my adapter The problem is that i get this error Error while processing route: index Assertion Failed: Unable to…
Koala7
  • 1,340
  • 7
  • 41
  • 83
0
votes
0 answers

Error Load Fixtures

When I use : php app/console doctrine:fixtures:load --fixtures=/var/www/Symfony/src/BISSAP/ForumBundle/DataFixtures/ORM I get : [Doctrine\DBAL\DBALException] …
Bissap
  • 521
  • 1
  • 5
  • 23
0
votes
2 answers

HTML code in Rails YAML-fixtures

HI, i have an "Article" model, that has HTML as it's content. I have created some test data with YAML fixtures and faced following problem: As i say "rake db:fixtures:load", following error appears: ArgumentError: syntax error on line 22, col 0:…
AntonAL
  • 16,692
  • 21
  • 80
  • 114
0
votes
0 answers

How to ignore Entity with Doctrine Entity Manager?

I'm working on a project using the latest version of the Symfony framework. I've got some entities that I have created once (I need to keep them for another functionality) but I don't want that the Doctrine Entity Manager purge them when I load new…
ge0ra
  • 53
  • 4
0
votes
1 answer

Meteor Fixtures

I have been working with this problem for 1 hour already and I cannot be any more frustrated than this. lib/categories_colection.js Categories = new Mongo.Collection('categories'); server/fixtures.js if (Categories.find().count === 0) { var…
Sang Yoo Kim
  • 365
  • 1
  • 15
0
votes
1 answer

Rails 4 fixtures aren't generating IDs (Hartl tutorial 9.6.2)

I'm creating an app based on the Hartl tutorial, and I'm stuck on the second exercise: Write an integration test for all the layout links, including the proper behavior for logged-in and non-logged-in users. Hint: Add to the test in Listing 5.25…
0
votes
2 answers

has_many :through creating child after_save --> ActionView::Template::Error

I have three models: List, Food, and Quantity. List and Food are associated through Quantity via has_many :through. The model association is doing what I want, but when I test, there is an error. test_valid_list_creation_information#ListsCreateTest…
0
votes
1 answer

Fixtures with polymorphic association not working

I'm trying to implement the Rolify gem but have trouble adding fixtures with a scope for it. The last line of the (model) test below fails because currently the moderator role seems to be given to @user globally instead of only for organization one.…
Nick
  • 3,496
  • 7
  • 42
  • 96
0
votes
1 answer

Rails style fixture deserializer for c#

Is there an open source deserializer in C# that could read a RoR style fixture into a given type? I tried googling it, but there really was not much that came up. It seems like a really simple thing that someone else has probably already…
Simon The Cat
  • 604
  • 1
  • 8
  • 22
0
votes
1 answer

symfony fixtures: set ondelete: CASCADE on refclass table

I'm using symfony 1.4.5, Doctrine 1.2 and Mysql 5. In my schema.yml I have a few Many-to-Many relations which work great. But I need the joining table to have onDelete: CASCADE. Now for doctrine it is needed to add onDelete: CASCADE on the side…
iggnition
  • 356
  • 6
  • 19
0
votes
1 answer

How to dump the database to yaml file with content '<% abc do %>ddd<% end %>'?

In my database, there are some text content, one of them is: <% abc do %> ddd <% end %> When I dumped it to yaml with to_yaml(), it is like: content: |- <% abc do %> ddd <% end %> And then, when I use rake db:fixtures:load, such error…
Freewind
  • 193,756
  • 157
  • 432
  • 708
0
votes
1 answer

Symfony2 functional tests + Doctrine fixtures: Changes to entity won't save after flushing in doctrine fixtures

I've encountered a problem while executing fixtures for my functional tests in Symfony 2.6. In the fixture I have a function for creating a base entity and flushing it to the database. Then I call this function from other functions that change the…
0
votes
2 answers

Model not being saved (Fixtures)

my recors are not being saved to the database after being created. I'm just using fixtures. I can see the model on the Ember addon when creating it in the form, but after hitting save, they dissappear and nothing happens. Also, when I select an item…
FranGoitia
  • 1,965
  • 3
  • 30
  • 49