summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2019-07-22 19:28:02 +0000
committerRobert Speicher <rspeicher@gmail.com>2019-07-22 19:28:02 +0000
commitfecafd824b22ced1fd7088f8099b9602c9e896e2 (patch)
tree915e32743ef32e9392e1e8d25bcff7adb7a02a7c
parent0e6c76a7bb1f8fa67d124b2ba013602af6579bce (diff)
parent46fef6f21dd4331d6436f67c0a875eefffd95bd0 (diff)
downloadgitlab-ce-fecafd824b22ced1fd7088f8099b9602c9e896e2.tar.gz
Merge branch 'resolve-remaining-import-export-differences' into 'master'
Resolve remaining import export differences See merge request gitlab-org/gitlab-ce!31012
-rw-r--r--spec/lib/gitlab/import_export/project.json3
-rw-r--r--spec/lib/gitlab/import_export/project_tree_saver_spec.rb7
-rw-r--r--spec/lib/gitlab/import_export/relation_rename_service_spec.rb1
3 files changed, 9 insertions, 2 deletions
diff --git a/spec/lib/gitlab/import_export/project.json b/spec/lib/gitlab/import_export/project.json
index c0b97486eeb..9e54ca28e58 100644
--- a/spec/lib/gitlab/import_export/project.json
+++ b/spec/lib/gitlab/import_export/project.json
@@ -2775,7 +2775,8 @@
"action": 1,
"author_id": 1
}
- ]
+ ],
+ "approvals_before_merge": 1
},
{
"id": 26,
diff --git a/spec/lib/gitlab/import_export/project_tree_saver_spec.rb b/spec/lib/gitlab/import_export/project_tree_saver_spec.rb
index bc4f867e891..5f56c30c7e0 100644
--- a/spec/lib/gitlab/import_export/project_tree_saver_spec.rb
+++ b/spec/lib/gitlab/import_export/project_tree_saver_spec.rb
@@ -42,6 +42,10 @@ describe Gitlab::ImportExport::ProjectTreeSaver do
expect(saved_project_json).to include({ 'description' => 'description', 'visibility_level' => 20 })
end
+ it 'has approvals_before_merge set' do
+ expect(saved_project_json['approvals_before_merge']).to eq(1)
+ end
+
it 'has milestones' do
expect(saved_project_json['milestones']).not_to be_empty
end
@@ -287,7 +291,8 @@ describe Gitlab::ImportExport::ProjectTreeSaver do
issues: [issue],
snippets: [snippet],
releases: [release],
- group: group
+ group: group,
+ approvals_before_merge: 1
)
project_label = create(:label, project: project)
group_label = create(:group_label, group: group)
diff --git a/spec/lib/gitlab/import_export/relation_rename_service_spec.rb b/spec/lib/gitlab/import_export/relation_rename_service_spec.rb
index a20a844a492..15748407f0c 100644
--- a/spec/lib/gitlab/import_export/relation_rename_service_spec.rb
+++ b/spec/lib/gitlab/import_export/relation_rename_service_spec.rb
@@ -28,6 +28,7 @@ describe Gitlab::ImportExport::RelationRenameService do
before do
allow(shared).to receive(:export_path).and_return(import_path)
+ allow(ActiveSupport::JSON).to receive(:decode).and_call_original
allow(ActiveSupport::JSON).to receive(:decode).with(file_content).and_return(json_file)
end