diff --git a/spec/models/project_spec.rb b/spec/models/project_spec.rb index 72284035b57..65b59c7b21b 100644 --- a/spec/models/project_spec.rb +++ b/spec/models/project_spec.rb @@ -3534,7 +3534,9 @@ describe Project do end it 'contains a URL variable for every supported API version' do - supported_versions = API::API.versions.select do |version| + # Ensure future API versions have proper variables defined. We're not doing this for v3. + supported_versions = API::API.versions - ['v3'] + supported_versions = supported_versions.select do |version| API::API.routes.select { |route| route.version == version }.many? end