Intercooler.js Test Suite

This is the test suite for the Intercooler.js library. Simply loading this page in a browser will run all the tests

New tests should follow the existing test templates, using the intercoolerTest() helper and mockjax for mocking out AJAX requests.

Run With data-* style attributes


Test Results

Intercooler.js

Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/137.0.0.0 Safari/537.36 Prerender (+https://github.com/prerender/prerender)

Running:
Intercooler.refresh() with path works

  1. IC attributes are set on elements (12)Rerun5 ms
    1. Has ID@ 1 ms
    2. Has Last Refresh@ 1 ms
    3. Has ID@ 1 ms
    4. Has Last Refresh@ 1 ms
    5. Has ID@ 1 ms
    6. Has Last Refresh@ 1 ms
    7. Has ID@ 4 ms
    8. Has Last Refresh@ 4 ms
    9. Has ID@ 4 ms
    10. Has Last Refresh@ 4 ms
    11. Has ID@ 4 ms
    12. Has Last Refresh@ 4 ms
  2. Javascript API Test (1)Rerun0 ms
    1. Should have returned null@ 0 ms
  3. Simple Update (2)Rerun121 ms
    1. Updated@ 0 ms
    2. Updated@ 107 ms
  4. Dependency update w/ POST (2)Rerun123 ms
    1. Updated@ 1 ms
    2. Updated@ 110 ms
  5. Dependency update w/ PUT (2)Rerun117 ms
    1. Updated@ 0 ms
    2. Updated@ 104 ms
  6. Dependency update w/ PATCH (2)Rerun118 ms
    1. Updated@ 0 ms
    2. Updated@ 104 ms
  7. Dependency update w/ DELETE (2)Rerun115 ms
    1. Updated@ 0 ms
    2. Updated@ 102 ms
  8. ic-get-from test (2)Rerun115 ms
    1. Pre@ 0 ms
    2. Updated@ 102 ms
  9. DELETE with removal (1)Rerun115 ms
    1. okay@ 101 ms
  10. Dependency on updated superpath (2)Rerun115 ms
    1. Updated@ 0 ms
    2. Updated@ 102 ms
  11. Dependency on updated subpath (2)Rerun117 ms
    1. Updated@ 0 ms
    2. Updated@ 104 ms
  12. partial path elements do not indicate a dependency (2)Rerun114 ms
    1. okay@ 1 ms
    2. okay@ 1 ms
  13. query string and hash arguments are stripped for dependency checks (2)Rerun114 ms
    1. okay@ 0 ms
    2. okay@ 0 ms
  14. empty path elements are discarded for isDependent (1)Rerun115 ms
    1. okay@ 0 ms
  15. Explicit dependency works (2)Rerun115 ms
    1. Updated@ 0 ms
    2. Updated@ 101 ms
  16. Prepend works properly (2)Rerun115 ms
    1. Pre-update@ 0 ms
    2. Updated@ 101 ms
  17. Append works properly (2)Rerun114 ms
    1. Pre-update@ 0 ms
    2. Updated@ 101 ms
  18. Eval header works (1)Rerun116 ms
    1. okay@ 103 ms
  19. Form submission works (1)Rerun119 ms
    1. okay@ 106 ms
  20. Form submission with submit button works (1)Rerun117 ms
    1. okay@ 102 ms
  21. Form submission works on direct form submission (1)Rerun115 ms
    1. okay@ 102 ms
  22. Intercooler.refresh() with element works (1)Rerun116 ms
    1. okay@ 102 ms
  23. Intercooler.refresh() with path worksRerun
    1. Test indicator as classRerun
      1. Test indicator as an attributeRerun
        1. Test indicator as an attribute on a parentRerun
          1. Target attribute worksRerun
            1. Target attribute works with appendRerun
              1. Target attribute works with prependRerun
                1. ic-limit-children works with prependRerun
                  1. ic-limit-children works with append and targetRerun
                    1. ic-include worksRerun
                      1. ic-trigger-on worksRerun
                        1. ic-verb worksRerun
                          1. ic-style-src updates styleRerun
                            1. ic-attr-src updates attrRerun
                              1. Log event happens properlyRerun
                                1. IC-Trigger HeaderRerun
                                  1. IC-Trigger Header With Single ArgRerun
                                    1. IC-Trigger Header With Array ArgsRerun
                                      1. IC-Trigger with JSON objectsRerun
                                        1. No double-wiring of events after a refreshRerun
                                          1. Children are wired in properlyRerun
                                            1. Scripts are evaluated onceRerun
                                              1. ic-on-beforeSend is invokedRerun
                                                1. ic-on-beforeSend is invoked on parentRerun
                                                  1. ic-replace-target replaces itselfRerun
                                                    1. ic-target with a closest expression worksRerun
                                                      1. ic-target with a find expression worksRerun
                                                        1. ic-trigger with a delay clause fires after delayRerun
                                                          1. ic-trigger with a delay does not cause multiple calls to issueRerun
                                                            1. trigger during request on element is caught and deferredRerun
                                                              1. only one deferred trigger is firedRerun
                                                                1. Child trigger worksRerun
                                                                  1. Current URL is presentRerun
                                                                    1. Basic history support worksRerun
                                                                      1. Get from with target worksRerun
                                                                        1. Basic partial response selector works properlyRerun
                                                                          1. Partial response selector works properly with append fromRerun
                                                                            1. Partial response selector works properly with prepend fromRerun
                                                                              1. ic-include works with JSON contentRerun
                                                                                1. test that js events are called correctlyRerun
                                                                                  1. Issue #44 complete event should fire on click with external ic-targetRerun
                                                                                    1. Issue #44 complete event should fire on click with self-replacing ic-targetRerun
                                                                                      1. Dependency update w/ POST Rerun
                                                                                        1. Test remove-afterRerun
                                                                                          1. Test ic-add-classRerun
                                                                                            1. Test ic-remove-classRerun
                                                                                              1. Test local transportRerun
                                                                                                1. Run initialization sets up pushstateRerun
                                                                                                  1. Test replaceOrAddMethodRerun
                                                                                                    1. Test ic-actionRerun
                                                                                                      1. Test beforeAjaxSend.ic can modify ajax setupRerun
                                                                                                        1. If testing w/ data, assert there are data-* attributesRerun

                                                                                                          Test HTML



                                                                                                          Javascript API Test
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          foo
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          Bar
                                                                                                          Foo
                                                                                                          loading...
                                                                                                          Foo
                                                                                                          loading...
                                                                                                          Foo
                                                                                                          Foo Foo Foo Text
                                                                                                          Foo
                                                                                                          0
                                                                                                          0
                                                                                                          0
                                                                                                          0
                                                                                                          History Test Get From
                                                                                                          click me! (self targeted)
                                                                                                          click me! (external target)
                                                                                                          Bar