Sha256: dfe1698e787d9bfc7b58a0b0822c6ff20874ab7826d1390f14832b4f35777fb2

Contents?: true

Size: 1001 Bytes

Versions: 23

Compression:

Stored size: 1001 Bytes

Contents

describe('Rails using rails fixtures examples', function() {
  beforeEach(() => {
    cy.app('clean') // have a look at cypress/app_commands/clean.rb
  })

  it('loading all fixtures', function() {
    cy.appFixtures()
    cy.visit('/')
    cy.get('table').find('tbody').should(($tbody) => {
      expect($tbody).to.contain('MyRailsFixtures')
      expect($tbody).to.contain('MyRailsFixtures2')
    })
  })

  it('using single rails fixtures', function() {
    cy.appFixtures({fixtures: ['posts']})
    cy.visit('/')
    cy.get('table').find('tbody').should(($tbody) => {
      expect($tbody).to.contain('MyRailsFixtures')
      expect($tbody).to.contain('MyRailsFixtures2')
    })
  })

  it('loading another folder of fixtures', function() {
    cy.appFixtures({fixtures_dir: 'test/cypress_fixtures' })
    cy.visit('/')
    cy.get('table').find('tbody').should(($tbody) => {
      expect($tbody).to.contain('MyCypressFixtures')
      expect($tbody).to.contain('MyCypressFixtures2')
    })
  })
})

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
cypress-on-rails-1.14.0 lib/generators/cypress_on_rails/templates/spec/cypress/e2e/rails_examples/using_fixtures.cy.js
cypress-on-rails-1.13.1 lib/generators/cypress_on_rails/templates/spec/cypress/e2e/rails_examples/using_fixtures.cy.js
cypress-on-rails-1.13.0 lib/generators/cypress_on_rails/templates/spec/cypress/e2e/rails_examples/using_fixtures.cy.js
cypress-on-rails-1.12.1 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.12.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.11.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.10.1 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.9.1 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.9.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.8.1 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.8.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.7.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.6.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.5.1 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.5.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures_spec.js
cypress-on-rails-1.4.2 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures.js
cypress-on-rails-1.4.1 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures.js
cypress-on-rails-1.4.0 lib/generators/cypress_on_rails/templates/spec/cypress/integration/rails_examples/using_fixtures.js
cypress-on-rails-1.3.0 lib/generators/cypress_dev/templates/spec/cypress/integration/rails_examples/using_fixtures.js
cypress-on-rails-1.2.1 lib/generators/cypress_dev/templates/spec/cypress/integration/rails_examples/using_fixtures.js