@@ -64,55 +64,53 @@ module WebDriver
64
64
end
65
65
end
66
66
67
- not_compliant_on :browser => :marionette do
68
- describe "cookie management" do
67
+ describe "cookie management" do
69
68
70
- it "should get all" do
71
- driver . navigate . to url_for ( "xhtmlTest.html" )
72
- driver . manage . add_cookie :name => "foo" , :value => "bar"
69
+ it "should get all" do
70
+ driver . navigate . to url_for ( "xhtmlTest.html" )
71
+ driver . manage . add_cookie :name => "foo" , :value => "bar"
73
72
74
- cookies = driver . manage . all_cookies
73
+ cookies = driver . manage . all_cookies
75
74
76
- expect ( cookies . size ) . to eq ( 1 )
77
- expect ( cookies . first [ :name ] ) . to eq ( "foo" )
78
- expect ( cookies . first [ :value ] ) . to eq ( "bar" )
79
- end
75
+ expect ( cookies . size ) . to eq ( 1 )
76
+ expect ( cookies . first [ :name ] ) . to eq ( "foo" )
77
+ expect ( cookies . first [ :value ] ) . to eq ( "bar" )
78
+ end
80
79
81
- # Edge BUG - https://connect.microsoft.com/IE/feedbackdetail/view/1864122
82
- not_compliant_on :browser => :edge do
83
- it "should delete one" do
84
- driver . navigate . to url_for ( "xhtmlTest.html" )
85
- driver . manage . add_cookie :name => "foo" , :value => "bar"
80
+ # Edge BUG - https://connect.microsoft.com/IE/feedbackdetail/view/1864122
81
+ not_compliant_on :browser => :edge do
82
+ it "should delete one" do
83
+ driver . navigate . to url_for ( "xhtmlTest.html" )
84
+ driver . manage . add_cookie :name => "foo" , :value => "bar"
86
85
87
- driver . manage . delete_cookie ( "foo" )
88
- end
86
+ driver . manage . delete_cookie ( "foo" )
89
87
end
88
+ end
90
89
91
- # This is not a w3c supported spec
92
- not_compliant_on :browser => :edge do
93
- it "should delete all" do
94
- driver . navigate . to url_for ( "xhtmlTest.html" )
90
+ # This is not a w3c supported spec
91
+ not_compliant_on :browser => :edge do
92
+ it "should delete all" do
93
+ driver . navigate . to url_for ( "xhtmlTest.html" )
95
94
96
- driver . manage . add_cookie :name => "foo" , :value => "bar"
97
- driver . manage . delete_all_cookies
98
- expect ( driver . manage . all_cookies ) . to be_empty
99
- end
95
+ driver . manage . add_cookie :name => "foo" , :value => "bar"
96
+ driver . manage . delete_all_cookies
97
+ expect ( driver . manage . all_cookies ) . to be_empty
100
98
end
99
+ end
101
100
102
- # Marionette BUG - Failed to convert expiry to Date
103
- not_compliant_on :browser => [ :android , :iphone , :safari , :marionette ] do
104
- it "should use DateTime for expires" do
105
- driver . navigate . to url_for ( "xhtmlTest.html" )
101
+ # Marionette BUG - Failed to convert expiry to Date
102
+ not_compliant_on :browser => [ :android , :iphone , :safari , :marionette ] do
103
+ it "should use DateTime for expires" do
104
+ driver . navigate . to url_for ( "xhtmlTest.html" )
106
105
107
- expected = DateTime . new ( 2039 )
108
- driver . manage . add_cookie :name => "foo" ,
109
- :value => "bar" ,
110
- :expires => expected
106
+ expected = DateTime . new ( 2039 )
107
+ driver . manage . add_cookie :name => "foo" ,
108
+ :value => "bar" ,
109
+ :expires => expected
111
110
112
- actual = driver . manage . cookie_named ( "foo" ) [ :expires ]
113
- expect ( actual ) . to be_kind_of ( DateTime )
114
- expect ( actual ) . to eq ( expected )
115
- end
111
+ actual = driver . manage . cookie_named ( "foo" ) [ :expires ]
112
+ expect ( actual ) . to be_kind_of ( DateTime )
113
+ expect ( actual ) . to eq ( expected )
116
114
end
117
115
end
118
116
end
0 commit comments