Commit 9789b56a authored by Robert Speicher's avatar Robert Speicher

Update ffaker gem

Adds a version requirement which it didn't have before, at 2.0.0. This
version has breaking API changes in that the namespace is now `FFaker`
instead of `Faker`.
parent 3601ebda
......@@ -239,7 +239,7 @@ group :development, :test do
gem 'minitest', '~> 5.3.0'
# Generate Fake data
gem "ffaker"
gem 'ffaker', '~> 2.0.0'
# Guard
gem 'guard-rspec'
......
......@@ -176,7 +176,7 @@ GEM
faraday_middleware (0.9.0)
faraday (>= 0.7.4, < 0.9)
fastercsv (1.5.5)
ffaker (1.22.1)
ffaker (2.0.0)
ffi (1.9.8)
fog (1.21.0)
fog-brightbox
......@@ -547,9 +547,9 @@ GEM
sdoc (0.3.20)
json (>= 1.1.3)
rdoc (~> 3.10)
seed-fu (2.3.1)
activerecord (>= 3.1, < 4.2)
activesupport (>= 3.1, < 4.2)
seed-fu (2.3.5)
activerecord (>= 3.1, < 4.3)
activesupport (>= 3.1, < 4.3)
select2-rails (3.5.2)
thor (~> 0.14)
settingslogic (2.0.9)
......@@ -713,7 +713,7 @@ DEPENDENCIES
email_spec
enumerize
factory_girl_rails
ffaker
ffaker (~> 2.0.0)
fog (~> 1.14)
font-awesome-rails (~> 4.2)
foreman
......
......@@ -23,7 +23,7 @@ Sidekiq::Testing.inline! do
name: group_path.titleize,
path: group_path
)
group.description = Faker::Lorem.sentence
group.description = FFaker::Lorem.sentence
group.save
group.add_owner(User.first)
......@@ -35,7 +35,7 @@ Sidekiq::Testing.inline! do
import_url: url,
namespace_id: group.id,
name: project_path.titleize,
description: Faker::Lorem.sentence,
description: FFaker::Lorem.sentence,
visibility_level: Gitlab::VisibilityLevel.values.sample
}
......
......@@ -2,9 +2,9 @@ Gitlab::Seeder.quiet do
(2..20).each do |i|
begin
User.create!(
username: Faker::Internet.user_name,
name: Faker::Name.name,
email: Faker::Internet.email,
username: FFaker::Internet.user_name,
name: FFaker::Name.name,
email: FFaker::Internet.email,
confirmed_at: DateTime.now,
password: '12345678'
)
......
......@@ -3,7 +3,7 @@ Gitlab::Seeder.quiet do
(1..5).each do |i|
milestone_params = {
title: "v#{i}.0",
description: Faker::Lorem.sentence,
description: FFaker::Lorem.sentence,
state: ['opened', 'closed'].sample,
}
......
......@@ -2,8 +2,8 @@ Gitlab::Seeder.quiet do
Project.all.each do |project|
(1..10).each do |i|
issue_params = {
title: Faker::Lorem.sentence(6),
description: Faker::Lorem.sentence,
title: FFaker::Lorem.sentence(6),
description: FFaker::Lorem.sentence,
state: ['opened', 'closed'].sample,
milestone: project.milestones.sample,
assignee: project.team.users.sample
......
......@@ -10,8 +10,8 @@ Gitlab::Seeder.quiet do
params = {
source_branch: source_branch,
target_branch: target_branch,
title: Faker::Lorem.sentence(6),
description: Faker::Lorem.sentences(3).join(" "),
title: FFaker::Lorem.sentence(6),
description: FFaker::Lorem.sentences(3).join(" "),
milestone: project.milestones.sample,
assignee: project.team.users.sample
}
......
......@@ -28,8 +28,8 @@ eos
PersonalSnippet.seed(:id, [{
id: i,
author_id: user.id,
title: Faker::Lorem.sentence(3),
file_name: Faker::Internet.domain_word + '.rb',
title: FFaker::Lorem.sentence(3),
file_name: FFaker::Internet.domain_word + '.rb',
visibility_level: Gitlab::VisibilityLevel.values.sample,
content: content,
}])
......
......@@ -6,7 +6,7 @@ Gitlab::Seeder.quiet do
note_params = {
noteable_type: 'Issue',
noteable_id: issue.id,
note: Faker::Lorem.sentence,
note: FFaker::Lorem.sentence,
}
Notes::CreateService.new(project, user, note_params).execute
......@@ -21,7 +21,7 @@ Gitlab::Seeder.quiet do
note_params = {
noteable_type: 'MergeRequest',
noteable_id: mr.id,
note: Faker::Lorem.sentence,
note: FFaker::Lorem.sentence,
}
Notes::CreateService.new(project, user, note_params).execute
......
......@@ -23,7 +23,7 @@ class Spinach::Features::ProjectHooks < Spinach::FeatureSteps
end
step 'I submit new hook' do
@url = Faker::Internet.uri("http")
@url = FFaker::Internet.uri("http")
fill_in "hook_url", with: @url
expect { click_button "Add Web Hook" }.to change(ProjectHook, :count).by(1)
end
......
......@@ -2,23 +2,23 @@ include ActionDispatch::TestProcess
FactoryGirl.define do
sequence :sentence, aliases: [:title, :content] do
Faker::Lorem.sentence
FFaker::Lorem.sentence
end
sequence :name do
Faker::Name.name
FFaker::Name.name
end
sequence :file_name do
Faker::Internet.user_name
FFaker::Internet.user_name
end
sequence(:url) { Faker::Internet.uri('http') }
sequence(:url) { FFaker::Internet.uri('http') }
factory :user, aliases: [:author, :assignee, :owner, :creator] do
email { Faker::Internet.email }
email { FFaker::Internet.email }
name
sequence(:username) { |n| "#{Faker::Internet.user_name}#{n}" }
sequence(:username) { |n| "#{FFaker::Internet.user_name}#{n}" }
password "12345678"
confirmed_at { Time.now }
confirmation_token { nil }
......@@ -122,12 +122,12 @@ FactoryGirl.define do
factory :email do
user
email do
Faker::Internet.email('alias')
FFaker::Internet.email('alias')
end
factory :another_email do
email do
Faker::Internet.email('another.alias')
FFaker::Internet.email('another.alias')
end
end
end
......
......@@ -26,7 +26,7 @@ describe "Admin::Hooks", feature: true do
describe "New Hook" do
before do
@url = Faker::Internet.uri("http")
@url = FFaker::Internet.uri("http")
visit admin_hooks_path
fill_in "hook_url", with: @url
expect { click_button "Add System Hook" }.to change(SystemHook, :count).by(1)
......
......@@ -185,7 +185,7 @@ describe Notify do
context 'for issues' do
let(:issue) { create(:issue, author: current_user, assignee: assignee, project: project) }
let(:issue_with_description) { create(:issue, author: current_user, assignee: assignee, project: project, description: Faker::Lorem.sentence) }
let(:issue_with_description) { create(:issue, author: current_user, assignee: assignee, project: project, description: FFaker::Lorem.sentence) }
describe 'that are new' do
subject { Notify.new_issue_email(issue.assignee_id, issue.id) }
......@@ -273,7 +273,7 @@ describe Notify do
context 'for merge requests' do
let(:merge_author) { create(:user) }
let(:merge_request) { create(:merge_request, author: current_user, assignee: assignee, source_project: project, target_project: project) }
let(:merge_request_with_description) { create(:merge_request, author: current_user, assignee: assignee, source_project: project, target_project: project, description: Faker::Lorem.sentence) }
let(:merge_request_with_description) { create(:merge_request, author: current_user, assignee: assignee, source_project: project, target_project: project, description: FFaker::Lorem.sentence) }
describe 'that are new' do
subject { Notify.new_merge_request_email(merge_request.assignee_id, merge_request.id) }
......
......@@ -165,7 +165,7 @@ describe API::API, api: true do
it "should assign attributes to project" do
project = attributes_for(:project, {
path: 'camelCasePath',
description: Faker::Lorem.sentence,
description: FFaker::Lorem.sentence,
issues_enabled: false,
merge_requests_enabled: false,
wiki_enabled: false
......@@ -274,7 +274,7 @@ describe API::API, api: true do
it 'should assign attributes to project' do
project = attributes_for(:project, {
description: Faker::Lorem.sentence,
description: FFaker::Lorem.sentence,
issues_enabled: false,
merge_requests_enabled: false,
wiki_enabled: false
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment