diff options
author | Rémy Coutable <remy@rymai.me> | 2017-03-23 16:08:39 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2017-04-03 19:54:48 +0300 |
commit | 4e3516788fdea3de3c5f06e1981ddc518b05d0fb (patch) | |
tree | d83183c2dfb8c5082a9d5a9fbcda6a5479c7d9fd /spec/features/profiles/personal_access_tokens_spec.rb | |
parent | ca6a7f1e9c9296317315249de9b8b3803d1c6ddc (diff) |
Don't use FFaker in factories, use sequences instead
FFaker can generate data that randomly break our test suite. This
simplifies our factories and use sequences which are more predictive.
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'spec/features/profiles/personal_access_tokens_spec.rb')
-rw-r--r-- | spec/features/profiles/personal_access_tokens_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/features/profiles/personal_access_tokens_spec.rb b/spec/features/profiles/personal_access_tokens_spec.rb index 0917d4dc3ef..99fba594651 100644 --- a/spec/features/profiles/personal_access_tokens_spec.rb +++ b/spec/features/profiles/personal_access_tokens_spec.rb @@ -27,7 +27,7 @@ describe 'Profile > Personal Access Tokens', feature: true, js: true do describe "token creation" do it "allows creation of a personal access token" do - name = FFaker::Product.brand + name = 'My PAT' visit profile_personal_access_tokens_path fill_in "Name", with: name @@ -52,7 +52,7 @@ describe 'Profile > Personal Access Tokens', feature: true, js: true do it "displays an error message" do disallow_personal_access_token_saves! visit profile_personal_access_tokens_path - fill_in "Name", with: FFaker::Product.brand + fill_in "Name", with: 'My PAT' expect { click_on "Create Personal Access Token" }.not_to change { PersonalAccessToken.count } expect(page).to have_content("Name cannot be nil") |