terminus 0.3.0 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (44) hide show
  1. data/README.rdoc +25 -19
  2. data/bin/terminus +1 -1
  3. data/lib/capybara/driver/terminus.rb +28 -17
  4. data/lib/terminus.rb +29 -15
  5. data/lib/terminus/application.rb +5 -11
  6. data/lib/terminus/browser.rb +97 -44
  7. data/lib/terminus/client.rb +43 -0
  8. data/lib/terminus/client/browser.rb +30 -0
  9. data/lib/terminus/client/phantom.js +6 -0
  10. data/lib/terminus/client/phantomjs.rb +20 -0
  11. data/lib/terminus/connector.rb +9 -0
  12. data/lib/terminus/connector/server.rb +142 -0
  13. data/lib/terminus/connector/socket_handler.rb +72 -0
  14. data/lib/terminus/controller.rb +22 -5
  15. data/lib/terminus/host.rb +7 -2
  16. data/lib/terminus/node.rb +11 -5
  17. data/lib/terminus/proxy.rb +35 -1
  18. data/lib/terminus/proxy/driver_body.rb +26 -6
  19. data/lib/terminus/proxy/external.rb +9 -0
  20. data/lib/terminus/proxy/rewrite.rb +4 -2
  21. data/lib/terminus/public/compiled/terminus-min.js +3 -0
  22. data/lib/terminus/public/compiled/terminus.js +5270 -0
  23. data/lib/terminus/public/loader.js +1 -1
  24. data/lib/terminus/public/pathology.js +3174 -0
  25. data/lib/terminus/public/syn/browsers.js +2 -2
  26. data/lib/terminus/public/syn/drag/drag.js +3 -4
  27. data/lib/terminus/public/syn/key.js +130 -111
  28. data/lib/terminus/public/syn/mouse.js +2 -2
  29. data/lib/terminus/public/syn/synthetic.js +45 -34
  30. data/lib/terminus/public/terminus.js +183 -70
  31. data/lib/terminus/server.rb +6 -0
  32. data/lib/terminus/timeouts.rb +4 -2
  33. data/lib/terminus/views/bootstrap.erb +12 -27
  34. data/lib/terminus/views/index.erb +1 -1
  35. data/spec/reports/android.txt +875 -0
  36. data/spec/reports/chrome.txt +137 -8
  37. data/spec/reports/firefox.txt +137 -9
  38. data/spec/reports/opera.txt +142 -13
  39. data/spec/reports/phantomjs.txt +871 -0
  40. data/spec/reports/safari.txt +137 -8
  41. data/spec/spec_helper.rb +19 -17
  42. data/spec/terminus_driver_spec.rb +8 -6
  43. data/spec/terminus_session_spec.rb +4 -4
  44. metadata +209 -117
@@ -26,10 +26,6 @@ Capybara::Driver::Terminus
26
26
  should extract node checked state
27
27
  should extract node selected state
28
28
  should return document text on /html selector
29
- it should behave like driver with header support
30
- should make headers available through response_headers
31
- it should behave like driver with status code support
32
- should make the status code available through status_code
33
29
  it should behave like driver with javascript support
34
30
  #find
35
31
  should find dynamically changed nodes
@@ -45,6 +41,10 @@ Capybara::Driver::Terminus
45
41
  should not wait for ajax requests to finish
46
42
  with short synchronization timeout
47
43
  should raise an error
44
+ it should behave like driver with header support
45
+ should make headers available through response_headers
46
+ it should behave like driver with status code support
47
+ should make the status code available through status_code
48
48
  it should behave like driver with frame support
49
49
  #within_frame
50
50
  should find the div in frameOne
@@ -238,6 +238,7 @@ Capybara::Session
238
238
  should raise an error
239
239
  it should behave like click_link
240
240
  #click_link
241
+ should follow relative links
241
242
  should follow redirects
242
243
  should follow redirects
243
244
  should add query string to current URL with naked query string
@@ -311,6 +312,7 @@ Capybara::Session
311
312
  the returned node
312
313
  should act like a session object
313
314
  should scope CSS selectors
315
+ should have a reference to its parent if there is one
314
316
  with css selectors
315
317
  should find the first element using the given locator
316
318
  with id selectors
@@ -659,11 +661,14 @@ Capybara::Session
659
661
  #within
660
662
  with CSS selector
661
663
  should click links in the given scope
664
+ should assert content in the given scope
662
665
  should accept additional options
663
666
  with XPath selector
664
667
  should click links in the given scope
665
668
  with the default selector
666
669
  should use XPath
670
+ with Node rather than selector
671
+ should click links in the given scope
667
672
  with the default selector set to CSS
668
673
  should use CSS
669
674
  with click_link
@@ -695,16 +700,23 @@ Capybara::Session
695
700
  is affected by following an absolute link
696
701
  is unaffected by posting through a relative form
697
702
  is affected by posting through an absolute form
703
+ is affected by following a redirect
698
704
  it should behave like session with headers support
699
705
  #response_headers
700
706
  should return response headers
701
- it should behave like session with status code support
702
- #status_code
703
- should return response codes
704
707
  it should behave like session with javascript support
705
708
  all JS specs
706
709
  Node#drag_to
707
710
  should drag and drop an object
711
+ Node#reload
712
+ without automatic reload
713
+ should reload the current context of the node
714
+ should reload a parent node
715
+ should not automatically reload
716
+ with automatic reload
717
+ should reload the current context of the node automatically
718
+ should reload a parent node automatically
719
+ should reload a node automatically when using find
708
720
  #find
709
721
  should allow triggering of custom JS events
710
722
  #body
@@ -717,6 +729,8 @@ Capybara::Session
717
729
  should execute the given script and return nothing
718
730
  #find
719
731
  should wait for asynchronous load
732
+ with frozen time
733
+ raises an error suggesting that Capybara is stuck in time
720
734
  #wait_until
721
735
  should wait for block to return true
722
736
  should raise Capybara::TimeoutError if block doesn't return true within timeout
@@ -744,5 +758,120 @@ Capybara::Session
744
758
  should wait for content to appear
745
759
  #has_no_content?
746
760
  should wait for content to disappear
761
+ it should behave like session with status code support
762
+ #status_code
763
+ should return response codes
764
+
765
+ Failures:
766
+
767
+ 1) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by id
768
+ Failure/Error: @session.attach_file "form_image", __FILE__
769
+ Capybara::NotSupportedByDriverError:
770
+ Capybara::NotSupportedByDriverError
771
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
772
+ # ./lib/terminus/node.rb:52:in `set'
773
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
774
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
775
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
776
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
777
+ # (eval):2:in `attach_file'
778
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:12:in `block (4 levels) in <top (required)>'
779
+
780
+ 2) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by label
781
+ Failure/Error: @session.attach_file "Image", __FILE__
782
+ Capybara::NotSupportedByDriverError:
783
+ Capybara::NotSupportedByDriverError
784
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
785
+ # ./lib/terminus/node.rb:52:in `set'
786
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
787
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
788
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
789
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
790
+ # (eval):2:in `attach_file'
791
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:18:in `block (4 levels) in <top (required)>'
792
+
793
+ 3) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by id
794
+ Failure/Error: @session.attach_file "form_document", @test_file_path
795
+ Capybara::NotSupportedByDriverError:
796
+ Capybara::NotSupportedByDriverError
797
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
798
+ # ./lib/terminus/node.rb:52:in `set'
799
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
800
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
801
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
802
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
803
+ # (eval):2:in `attach_file'
804
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:26:in `block (4 levels) in <top (required)>'
805
+
806
+ 4) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by label
807
+ Failure/Error: @session.attach_file "Document", @test_file_path
808
+ Capybara::NotSupportedByDriverError:
809
+ Capybara::NotSupportedByDriverError
810
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
811
+ # ./lib/terminus/node.rb:52:in `set'
812
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
813
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
814
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
815
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
816
+ # (eval):2:in `attach_file'
817
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:32:in `block (4 levels) in <top (required)>'
818
+
819
+ 5) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type text/plain when uploading a text file
820
+ Failure/Error: @session.attach_file "Document", @test_file_path
821
+ Capybara::NotSupportedByDriverError:
822
+ Capybara::NotSupportedByDriverError
823
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
824
+ # ./lib/terminus/node.rb:52:in `set'
825
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
826
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
827
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
828
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
829
+ # (eval):2:in `attach_file'
830
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:43:in `block (4 levels) in <top (required)>'
831
+
832
+ 6) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type image/jpeg when uploading an image
833
+ Failure/Error: @session.attach_file "Document", @test_jpg_file_path
834
+ Capybara::NotSupportedByDriverError:
835
+ Capybara::NotSupportedByDriverError
836
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
837
+ # ./lib/terminus/node.rb:52:in `set'
838
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
839
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
840
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
841
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
842
+ # (eval):2:in `attach_file'
843
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:49:in `block (4 levels) in <top (required)>'
844
+
845
+ 7) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should not break when using HTML5 multiple file input
846
+ Failure/Error: @session.attach_file "Multiple Documents", @test_file_path
847
+ Capybara::NotSupportedByDriverError:
848
+ Capybara::NotSupportedByDriverError
849
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
850
+ # ./lib/terminus/node.rb:52:in `set'
851
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
852
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
853
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
854
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
855
+ # (eval):2:in `attach_file'
856
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:55:in `block (4 levels) in <top (required)>'
857
+
858
+ 8) Capybara::Session with terminus driver it should behave like session it should behave like fill_in#fill_in should fill in a text field by label without for
859
+ Failure/Error: extract_results(@session)['street'].should == 'Avenue Q'
860
+ expected: "Avenue Q"
861
+ got: "Sesame street 66" (using ==)
862
+ Shared Example Group: "fill_in" called from ./vendor/capybara/lib/capybara/spec/session.rb:94
863
+ # ./vendor/capybara/lib/capybara/spec/session/fill_in_spec.rb:22:in `block (3 levels) in <top (required)>'
864
+
865
+ Finished in 4 minutes 7.05 seconds
866
+ 510 examples, 8 failures
867
+
868
+ Failed examples:
747
869
 
748
- 498 examples, 8 failures
870
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:11 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by id
871
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:17 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by label
872
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:25 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by id
873
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:31 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by label
874
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:42 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type text/plain when uploading a text file
875
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:48 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type image/jpeg when uploading an image
876
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:54 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should not break when using HTML5 multiple file input
877
+ rspec ./vendor/capybara/lib/capybara/spec/session/fill_in_spec.rb:19 # Capybara::Session with terminus driver it should behave like session it should behave like fill_in#fill_in should fill in a text field by label without for
@@ -26,10 +26,6 @@ Capybara::Driver::Terminus
26
26
  should extract node checked state
27
27
  should extract node selected state
28
28
  should return document text on /html selector
29
- it should behave like driver with header support
30
- should make headers available through response_headers
31
- it should behave like driver with status code support
32
- should make the status code available through status_code
33
29
  it should behave like driver with javascript support
34
30
  #find
35
31
  should find dynamically changed nodes
@@ -45,6 +41,10 @@ Capybara::Driver::Terminus
45
41
  should not wait for ajax requests to finish
46
42
  with short synchronization timeout
47
43
  should raise an error
44
+ it should behave like driver with header support
45
+ should make headers available through response_headers
46
+ it should behave like driver with status code support
47
+ should make the status code available through status_code
48
48
  it should behave like driver with frame support
49
49
  #within_frame
50
50
  should find the div in frameOne
@@ -238,6 +238,7 @@ Capybara::Session
238
238
  should raise an error
239
239
  it should behave like click_link
240
240
  #click_link
241
+ should follow relative links
241
242
  should follow redirects
242
243
  should follow redirects
243
244
  should add query string to current URL with naked query string
@@ -311,6 +312,7 @@ Capybara::Session
311
312
  the returned node
312
313
  should act like a session object
313
314
  should scope CSS selectors
315
+ should have a reference to its parent if there is one
314
316
  with css selectors
315
317
  should find the first element using the given locator
316
318
  with id selectors
@@ -659,11 +661,14 @@ Capybara::Session
659
661
  #within
660
662
  with CSS selector
661
663
  should click links in the given scope
664
+ should assert content in the given scope
662
665
  should accept additional options
663
666
  with XPath selector
664
667
  should click links in the given scope
665
668
  with the default selector
666
669
  should use XPath
670
+ with Node rather than selector
671
+ should click links in the given scope
667
672
  with the default selector set to CSS
668
673
  should use CSS
669
674
  with click_link
@@ -695,18 +700,25 @@ Capybara::Session
695
700
  is affected by following an absolute link
696
701
  is unaffected by posting through a relative form
697
702
  is affected by posting through an absolute form
703
+ is affected by following a redirect
698
704
  it should behave like session with headers support
699
705
  #response_headers
700
706
  should return response headers
701
- it should behave like session with status code support
702
- #status_code
703
- should return response codes
704
707
  it should behave like session with javascript support
705
708
  all JS specs
706
709
  Node#drag_to
707
710
  should drag and drop an object
711
+ Node#reload
712
+ without automatic reload
713
+ should reload the current context of the node
714
+ should reload a parent node
715
+ should not automatically reload
716
+ with automatic reload
717
+ should reload the current context of the node automatically
718
+ should reload a parent node automatically
719
+ should reload a node automatically when using find
708
720
  #find
709
- should allow triggering of custom JS events
721
+ should allow triggering of custom JS events (FAILED - 8)
710
722
  #body
711
723
  should return the current state of the page
712
724
  #source
@@ -717,6 +729,8 @@ Capybara::Session
717
729
  should execute the given script and return nothing
718
730
  #find
719
731
  should wait for asynchronous load
732
+ with frozen time
733
+ raises an error suggesting that Capybara is stuck in time
720
734
  #wait_until
721
735
  should wait for block to return true
722
736
  should raise Capybara::TimeoutError if block doesn't return true within timeout
@@ -744,5 +758,119 @@ Capybara::Session
744
758
  should wait for content to appear
745
759
  #has_no_content?
746
760
  should wait for content to disappear
761
+ it should behave like session with status code support
762
+ #status_code
763
+ should return response codes
764
+
765
+ Failures:
766
+
767
+ 1) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by id
768
+ Failure/Error: @session.attach_file "form_image", __FILE__
769
+ Capybara::NotSupportedByDriverError:
770
+ Capybara::NotSupportedByDriverError
771
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
772
+ # ./lib/terminus/node.rb:52:in `set'
773
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
774
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
775
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
776
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
777
+ # (eval):2:in `attach_file'
778
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:12:in `block (4 levels) in <top (required)>'
779
+
780
+ 2) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by label
781
+ Failure/Error: @session.attach_file "Image", __FILE__
782
+ Capybara::NotSupportedByDriverError:
783
+ Capybara::NotSupportedByDriverError
784
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
785
+ # ./lib/terminus/node.rb:52:in `set'
786
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
787
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
788
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
789
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
790
+ # (eval):2:in `attach_file'
791
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:18:in `block (4 levels) in <top (required)>'
792
+
793
+ 3) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by id
794
+ Failure/Error: @session.attach_file "form_document", @test_file_path
795
+ Capybara::NotSupportedByDriverError:
796
+ Capybara::NotSupportedByDriverError
797
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
798
+ # ./lib/terminus/node.rb:52:in `set'
799
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
800
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
801
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
802
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
803
+ # (eval):2:in `attach_file'
804
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:26:in `block (4 levels) in <top (required)>'
805
+
806
+ 4) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by label
807
+ Failure/Error: @session.attach_file "Document", @test_file_path
808
+ Capybara::NotSupportedByDriverError:
809
+ Capybara::NotSupportedByDriverError
810
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
811
+ # ./lib/terminus/node.rb:52:in `set'
812
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
813
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
814
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
815
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
816
+ # (eval):2:in `attach_file'
817
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:32:in `block (4 levels) in <top (required)>'
818
+
819
+ 5) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type text/plain when uploading a text file
820
+ Failure/Error: @session.attach_file "Document", @test_file_path
821
+ Capybara::NotSupportedByDriverError:
822
+ Capybara::NotSupportedByDriverError
823
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
824
+ # ./lib/terminus/node.rb:52:in `set'
825
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
826
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
827
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
828
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
829
+ # (eval):2:in `attach_file'
830
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:43:in `block (4 levels) in <top (required)>'
831
+
832
+ 6) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type image/jpeg when uploading an image
833
+ Failure/Error: @session.attach_file "Document", @test_jpg_file_path
834
+ Capybara::NotSupportedByDriverError:
835
+ Capybara::NotSupportedByDriverError
836
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
837
+ # ./lib/terminus/node.rb:52:in `set'
838
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
839
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
840
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
841
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
842
+ # (eval):2:in `attach_file'
843
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:49:in `block (4 levels) in <top (required)>'
844
+
845
+ 7) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should not break when using HTML5 multiple file input
846
+ Failure/Error: @session.attach_file "Multiple Documents", @test_file_path
847
+ Capybara::NotSupportedByDriverError:
848
+ Capybara::NotSupportedByDriverError
849
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
850
+ # ./lib/terminus/node.rb:52:in `set'
851
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
852
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
853
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
854
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
855
+ # (eval):2:in `attach_file'
856
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:55:in `block (4 levels) in <top (required)>'
857
+
858
+ 8) Capybara::Session with terminus driver it should behave like session with javascript support all JS specs#find should allow triggering of custom JS events
859
+ Failure/Error: @session.should have_css('#focus_event_triggered')
860
+ expected #has_css?("#focus_event_triggered") to return true, got false
861
+ Shared Example Group: "session with javascript support" called from ./spec/terminus_session_spec.rb:16
862
+ # ./vendor/capybara/lib/capybara/spec/session/javascript.rb:84:in `block (4 levels) in <top (required)>'
863
+
864
+ Finished in 5 minutes 52.66 seconds
865
+ 510 examples, 8 failures
866
+
867
+ Failed examples:
747
868
 
748
- 498 examples, 7 failures
869
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:11 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by id
870
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:17 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by label
871
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:25 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by id
872
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:31 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by label
873
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:42 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type text/plain when uploading a text file
874
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:48 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type image/jpeg when uploading an image
875
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:54 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should not break when using HTML5 multiple file input
876
+ rspec ./vendor/capybara/lib/capybara/spec/session/javascript.rb:80 # Capybara::Session with terminus driver it should behave like session with javascript support all JS specs#find should allow triggering of custom JS events
@@ -26,10 +26,6 @@ Capybara::Driver::Terminus
26
26
  should extract node checked state
27
27
  should extract node selected state
28
28
  should return document text on /html selector
29
- it should behave like driver with header support
30
- should make headers available through response_headers
31
- it should behave like driver with status code support
32
- should make the status code available through status_code
33
29
  it should behave like driver with javascript support
34
30
  #find
35
31
  should find dynamically changed nodes
@@ -45,6 +41,10 @@ Capybara::Driver::Terminus
45
41
  should not wait for ajax requests to finish
46
42
  with short synchronization timeout
47
43
  should raise an error
44
+ it should behave like driver with header support
45
+ should make headers available through response_headers
46
+ it should behave like driver with status code support
47
+ should make the status code available through status_code
48
48
  it should behave like driver with frame support
49
49
  #within_frame
50
50
  should find the div in frameOne
@@ -169,7 +169,7 @@ Capybara::Session
169
169
  should raise an error
170
170
  it should behave like click_button
171
171
  #click_button
172
- should serialize and send valueless buttons that were clicked (FAILED - 8)
172
+ should serialize and send valueless buttons that were clicked
173
173
  should not send image buttons that were not clicked
174
174
  should serialize and send GET forms
175
175
  should follow redirects
@@ -223,7 +223,7 @@ Capybara::Session
223
223
  with text given on a button defined by <button> tag
224
224
  should submit the associated form
225
225
  should work with partial matches
226
- should prefer exact matches over partial matches (FAILED - 9)
226
+ should prefer exact matches over partial matches
227
227
  with id given on a button defined by <button> tag
228
228
  should submit the associated form
229
229
  should serialize and send GET forms
@@ -238,11 +238,12 @@ Capybara::Session
238
238
  should raise an error
239
239
  it should behave like click_link
240
240
  #click_link
241
+ should follow relative links
241
242
  should follow redirects
242
243
  should follow redirects
243
244
  should add query string to current URL with naked query string
244
- should do nothing on anchor links (FAILED - 10)
245
- should do nothing on URL+anchor links for the same page (FAILED - 11)
245
+ should do nothing on anchor links
246
+ should do nothing on URL+anchor links for the same page
246
247
  should follow link on URL+anchor links for a different page
247
248
  raise an error with links with no href
248
249
  with id given
@@ -265,7 +266,7 @@ Capybara::Session
265
266
  #fill_in
266
267
  should fill in a text field by id
267
268
  should fill in a text field by name
268
- should fill in a text field by label without for (FAILED - 12)
269
+ should fill in a text field by label without for (FAILED - 8)
269
270
  should fill in a url field by label without for
270
271
  should favour exact label matches over partial matches
271
272
  should fill in a textarea by id
@@ -311,6 +312,7 @@ Capybara::Session
311
312
  the returned node
312
313
  should act like a session object
313
314
  should scope CSS selectors
315
+ should have a reference to its parent if there is one
314
316
  with css selectors
315
317
  should find the first element using the given locator
316
318
  with id selectors
@@ -659,11 +661,14 @@ Capybara::Session
659
661
  #within
660
662
  with CSS selector
661
663
  should click links in the given scope
664
+ should assert content in the given scope
662
665
  should accept additional options
663
666
  with XPath selector
664
667
  should click links in the given scope
665
668
  with the default selector
666
669
  should use XPath
670
+ with Node rather than selector
671
+ should click links in the given scope
667
672
  with the default selector set to CSS
668
673
  should use CSS
669
674
  with click_link
@@ -695,16 +700,23 @@ Capybara::Session
695
700
  is affected by following an absolute link
696
701
  is unaffected by posting through a relative form
697
702
  is affected by posting through an absolute form
703
+ is affected by following a redirect
698
704
  it should behave like session with headers support
699
705
  #response_headers
700
706
  should return response headers
701
- it should behave like session with status code support
702
- #status_code
703
- should return response codes
704
707
  it should behave like session with javascript support
705
708
  all JS specs
706
709
  Node#drag_to
707
710
  should drag and drop an object
711
+ Node#reload
712
+ without automatic reload
713
+ should reload the current context of the node
714
+ should reload a parent node
715
+ should not automatically reload
716
+ with automatic reload
717
+ should reload the current context of the node automatically
718
+ should reload a parent node automatically
719
+ should reload a node automatically when using find
708
720
  #find
709
721
  should allow triggering of custom JS events
710
722
  #body
@@ -717,6 +729,8 @@ Capybara::Session
717
729
  should execute the given script and return nothing
718
730
  #find
719
731
  should wait for asynchronous load
732
+ with frozen time
733
+ raises an error suggesting that Capybara is stuck in time
720
734
  #wait_until
721
735
  should wait for block to return true
722
736
  should raise Capybara::TimeoutError if block doesn't return true within timeout
@@ -744,5 +758,120 @@ Capybara::Session
744
758
  should wait for content to appear
745
759
  #has_no_content?
746
760
  should wait for content to disappear
761
+ it should behave like session with status code support
762
+ #status_code
763
+ should return response codes
764
+
765
+ Failures:
766
+
767
+ 1) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by id
768
+ Failure/Error: @session.attach_file "form_image", __FILE__
769
+ Capybara::NotSupportedByDriverError:
770
+ Capybara::NotSupportedByDriverError
771
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
772
+ # ./lib/terminus/node.rb:52:in `set'
773
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
774
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
775
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
776
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
777
+ # (eval):2:in `attach_file'
778
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:12:in `block (4 levels) in <top (required)>'
779
+
780
+ 2) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by label
781
+ Failure/Error: @session.attach_file "Image", __FILE__
782
+ Capybara::NotSupportedByDriverError:
783
+ Capybara::NotSupportedByDriverError
784
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
785
+ # ./lib/terminus/node.rb:52:in `set'
786
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
787
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
788
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
789
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
790
+ # (eval):2:in `attach_file'
791
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:18:in `block (4 levels) in <top (required)>'
792
+
793
+ 3) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by id
794
+ Failure/Error: @session.attach_file "form_document", @test_file_path
795
+ Capybara::NotSupportedByDriverError:
796
+ Capybara::NotSupportedByDriverError
797
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
798
+ # ./lib/terminus/node.rb:52:in `set'
799
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
800
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
801
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
802
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
803
+ # (eval):2:in `attach_file'
804
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:26:in `block (4 levels) in <top (required)>'
805
+
806
+ 4) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by label
807
+ Failure/Error: @session.attach_file "Document", @test_file_path
808
+ Capybara::NotSupportedByDriverError:
809
+ Capybara::NotSupportedByDriverError
810
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
811
+ # ./lib/terminus/node.rb:52:in `set'
812
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
813
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
814
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
815
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
816
+ # (eval):2:in `attach_file'
817
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:32:in `block (4 levels) in <top (required)>'
818
+
819
+ 5) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type text/plain when uploading a text file
820
+ Failure/Error: @session.attach_file "Document", @test_file_path
821
+ Capybara::NotSupportedByDriverError:
822
+ Capybara::NotSupportedByDriverError
823
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
824
+ # ./lib/terminus/node.rb:52:in `set'
825
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
826
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
827
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
828
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
829
+ # (eval):2:in `attach_file'
830
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:43:in `block (4 levels) in <top (required)>'
831
+
832
+ 6) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type image/jpeg when uploading an image
833
+ Failure/Error: @session.attach_file "Document", @test_jpg_file_path
834
+ Capybara::NotSupportedByDriverError:
835
+ Capybara::NotSupportedByDriverError
836
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
837
+ # ./lib/terminus/node.rb:52:in `set'
838
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
839
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
840
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
841
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
842
+ # (eval):2:in `attach_file'
843
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:49:in `block (4 levels) in <top (required)>'
844
+
845
+ 7) Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should not break when using HTML5 multiple file input
846
+ Failure/Error: @session.attach_file "Multiple Documents", @test_file_path
847
+ Capybara::NotSupportedByDriverError:
848
+ Capybara::NotSupportedByDriverError
849
+ Shared Example Group: "attach_file" called from ./vendor/capybara/lib/capybara/spec/session.rb:88
850
+ # ./lib/terminus/node.rb:52:in `set'
851
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `block in set'
852
+ # ./vendor/capybara/lib/capybara/node/base.rb:46:in `wait_until'
853
+ # ./vendor/capybara/lib/capybara/node/element.rb:75:in `set'
854
+ # ./vendor/capybara/lib/capybara/node/actions.rb:158:in `attach_file'
855
+ # (eval):2:in `attach_file'
856
+ # ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:55:in `block (4 levels) in <top (required)>'
857
+
858
+ 8) Capybara::Session with terminus driver it should behave like session it should behave like fill_in#fill_in should fill in a text field by label without for
859
+ Failure/Error: extract_results(@session)['street'].should == 'Avenue Q'
860
+ expected: "Avenue Q"
861
+ got: "Sesame street 66" (using ==)
862
+ Shared Example Group: "fill_in" called from ./vendor/capybara/lib/capybara/spec/session.rb:94
863
+ # ./vendor/capybara/lib/capybara/spec/session/fill_in_spec.rb:22:in `block (3 levels) in <top (required)>'
864
+
865
+ Finished in 10 minutes 8.65 seconds
866
+ 510 examples, 8 failures
867
+
868
+ Failed examples:
747
869
 
748
- 498 examples, 12 failures
870
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:11 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by id
871
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:17 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with normal form should set a file path by label
872
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:25 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by id
873
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:31 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should set a file path by label
874
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:42 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type text/plain when uploading a text file
875
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:48 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should send content type image/jpeg when uploading an image
876
+ rspec ./vendor/capybara/lib/capybara/spec/session/attach_file_spec.rb:54 # Capybara::Session with terminus driver it should behave like session it should behave like attach_file#attach_file with multipart form should not break when using HTML5 multiple file input
877
+ rspec ./vendor/capybara/lib/capybara/spec/session/fill_in_spec.rb:19 # Capybara::Session with terminus driver it should behave like session it should behave like fill_in#fill_in should fill in a text field by label without for