mirror of
https://github.com/bigskysoftware/htmx.git
synced 2025-09-27 04:50:43 +00:00
disable history tests in headless mode
This commit is contained in:
parent
14bea6c58e
commit
f3d79dc505
2
TODO.md
2
TODO.md
@ -18,7 +18,7 @@
|
|||||||
* Issue GET to restore content if there isn't a copy locally
|
* Issue GET to restore content if there isn't a copy locally
|
||||||
* sse support
|
* sse support
|
||||||
* polling (ic-trigger="every 2s")
|
* polling (ic-trigger="every 2s")
|
||||||
* delay (ic-trigger="keyup delay 1s")
|
* delay (ic-trigger="keyup" ic-delay="1s")
|
||||||
* implement element properties using https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap
|
* implement element properties using https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap
|
||||||
* make node handling idempotent
|
* make node handling idempotent
|
||||||
* don't cancel trigger events, but don't process additional events
|
* don't cancel trigger events, but don't process additional events
|
||||||
|
@ -1,4 +1,11 @@
|
|||||||
describe("HTMx History Tests", function() {
|
describe("HTMx History Tests", function() {
|
||||||
|
|
||||||
|
if (document.location.href.indexOf("file:") === 0) {
|
||||||
|
it("HISTORY TESTING SKIPPED IN HEADLESS MODE"), function() {
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
beforeEach(function () {
|
beforeEach(function () {
|
||||||
this.server = sinon.fakeServer.create();
|
this.server = sinon.fakeServer.create();
|
||||||
clearWorkArea();
|
clearWorkArea();
|
||||||
@ -15,7 +22,7 @@ describe("HTMx History Tests", function() {
|
|||||||
var div = make('<div hx-push-url="true" hx-get="/test">first</div>');
|
var div = make('<div hx-push-url="true" hx-get="/test">first</div>');
|
||||||
div.click();
|
div.click();
|
||||||
this.server.respond();
|
this.server.respond();
|
||||||
getWorkArea().innerHTML.should.be.equal("<div hx-push-url=\"true\" hx-get=\"/test\">second</div>")
|
getWorkArea().innerHTML.should.equal("<div hx-push-url=\"true\" hx-get=\"/test\">second</div>")
|
||||||
history.back();
|
history.back();
|
||||||
setTimeout(function(){
|
setTimeout(function(){
|
||||||
getWorkArea().innerHTML.should.be.equal("<div hx-push-url=\"true\" hx-get=\"/test\">first</div>");
|
getWorkArea().innerHTML.should.be.equal("<div hx-push-url=\"true\" hx-get=\"/test\">first</div>");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user