import { haveText, html, test } from '../../utils'
// Skipping these tests because the plugin has been moved to livewire/livewire until it's stablhese tests because the plugin has been moved to livewire/livewire until it's stable...
describe.skip('History tests', function () {
test('value is reflected in query string upon changing',
[html`
Dec
`],
({ get, url, go }) => {
get('span').should(haveText('1'))
url().should('not.include', '?count=1')
get('button').click()
get('span').should(haveText('2'))
url().should('include', '?count=2')
get('button').click()
get('span').should(haveText('3'))
url().should('include', '?count=3')
get('h1').click()
get('h1').click()
get('span').should(haveText('1'))
url().should('not.include', '?count=1')
},
)
test('can configure always making the query string value present',
[html`
Dec
`],
({ get, url, go }) => {
get('span').should(haveText('1'))
url().should('include', '?count=1')
get('button').click()
get('span').should(haveText('2'))
url().should('include', '?count=2')
get('h1').click()
get('span').should(haveText('1'))
url().should('include', '?count=1')
},
)
test('value is persisted across requests',
[html`
`],
({ get, url, go }, reload) => {
get('span').should(haveText('1'))
url().should('not.include', '?count=1')
get('button').click()
get('span').should(haveText('2'))
url().should('include', '?count=2')
reload()
url().should('include', '?count=2')
get('span').should(haveText('2'))
},
)
test('can provide an alias',
[html`