Sha256: b21028f6d2704e46fdd1d16cca2d1149b4a36f4cfcf5c6595c468bcce612dfa5

Contents?: true

Size: 621 Bytes

Versions: 24

Compression:

Stored size: 621 Bytes

Contents

u = up.util

replaceStateHelperCount = 0

beforeAll ->
  @hrefBeforeSuite = location.href
  @titleBeforeSuite = document.title

afterAll (done) ->
  up.util.nextFrame =>
    history.replaceState?({ fromResetPathHelper: true }, '', @hrefBeforeSuite)
    document.title = @titleBeforeSuite
    done()

beforeEach ->
  # Webkit ignores replaceState() calls after 100 calls / 30 sec.
  # So specs need to explicitely activate history handling.
  up.history.config.enabled = false

  # Store original URL and title so we can restore it in afterEach.
  @hrefBeforeExample = location.href
  @titleBeforeExample = document.title

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
unpoly-rails-0.51.0 spec_app/spec/javascripts/helpers/reset_history.js.coffee
unpoly-rails-0.50.2 spec_app/spec/javascripts/helpers/reset_history.js.coffee
unpoly-rails-0.50.1 spec_app/spec/javascripts/helpers/reset_history.js.coffee
unpoly-rails-0.50.0 spec_app/spec/javascripts/helpers/reset_history.js.coffee