Commit 35a4a84e authored by Nick Thomas's avatar Nick Thomas

Merge branch 'cablett-refactor-test' into 'master'

Refactor issue designs tests to use nodes

See merge request gitlab-org/gitlab!44887
parents 826711fa 89d2368c
......@@ -31,8 +31,8 @@ RSpec.describe 'Getting designs related to an issue' do
post_graphql(query(note_fields), current_user: nil)
designs_data = graphql_data['project']['issue']['designs']['designs']
design_data = designs_data['edges'].first['node']
note_data = design_data['notes']['edges'].first['node']
design_data = designs_data['nodes'].first
note_data = design_data['notes']['nodes'].first
expect(note_data['id']).to eq(note.to_global_id.to_s)
end
......@@ -40,14 +40,10 @@ RSpec.describe 'Getting designs related to an issue' do
def query(note_fields = all_graphql_fields_for(Note))
design_node = <<~NODE
designs {
edges {
node {
notes {
edges {
node {
#{note_fields}
}
}
nodes {
notes {
nodes {
#{note_fields}
}
}
}
......
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