黄瓜中的步骤定义

发布于 2024-10-05 14:13:35 字数 321 浏览 0 评论 0原文

我有一个 Rails 应用程序,它有一个 Account 类,该类有一个或多个与之相关的用户;每个用户都有自己的登录凭据,但应用程序始终检查 current_account。

我正在尝试编写一个黄瓜功能,其中包括经典的“假设用户已登录...”,并且在steps_definitions文件中,我需要知道如何在创建用户对象之前表达Account类。

实际上,创建用户是没有问题的,当我>>>时,它就成了问题。 click_button“登录”

所以...确保我有一个帐户的最佳方法是什么(顺便说一句,需要订阅,这需要订阅计划以及创建之前的所有爵士乐...

I have a Rails app that has an Account class which has one or more users related to it; each user has their login credential, but the app always check for the current_account.

I am trying to write a cucumber feature that includes the classic 'given a user is logged in...', and in the steps_definitions file, I need to know how to express the Account class before creating a user object.

Actually, creating the user is no problem, it becomes a problem when I >>
click_button 'login'

so... what's the best approach to make sure I have an account (which, by the way, requires a subscription, which requires a subscription plan and all that jazz before they're created...

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文