我想展示一种行为,该行为基本上表明路径“/”适用于 http 域,并且转到路径“/users/sign_in”会强制重定向到 https。你怎么能说明这一点?这是否属于控制器、请求或路由规范?
规范看起来像:
describe "https redirection" do
context "when http" do
it "forces a permanent redirect to /users/sign_in on https when path is /users/sign_in" do
end
it "returns status of 200 when path is /"
end
end
context "when https" do
it "returns status of 200 when path is /users/sign_in"
end
end
end