Skip to content
代码片段 群组 项目
未验证 提交 2846ed2e 编辑于 作者: Pedro Pombeiro's avatar Pedro Pombeiro 提交者: GitLab
浏览文件

Merge branch 'jivanvl/exposeFieldTypeBuildArtifactEntity' into 'master'

Expose file_type field in the BuildArtifactEntity

See merge request https://gitlab.com/gitlab-org/gitlab/-/merge_requests/177155



Merged-by: default avatarPedro Pombeiro <noreply@pedro.pombei.ro>
Approved-by: default avatarPedro Pombeiro <noreply@pedro.pombei.ro>
Co-authored-by: default avatarJose Ivan Vargas <jvargas@gitlab.com>
No related branches found
No related tags found
无相关合并请求
...@@ -10,6 +10,8 @@ class BuildArtifactEntity < Grape::Entity ...@@ -10,6 +10,8 @@ class BuildArtifactEntity < Grape::Entity
"#{artifact.job.name}:#{artifact.file_type}" "#{artifact.job.name}:#{artifact.file_type}"
end end
expose :file_type
expose :expire_at expose :expire_at
expose :expired?, as: :expired expose :expired?, as: :expired
......
...@@ -19,6 +19,10 @@ ...@@ -19,6 +19,10 @@
expect(subject[:name]).to eq "test:codequality" expect(subject[:name]).to eq "test:codequality"
end end
it 'exposes information about the file type' do
expect(subject).to include(:file_type)
end
it 'exposes information about expiration of artifacts' do it 'exposes information about expiration of artifacts' do
expect(subject).to include(:expired, :expire_at) expect(subject).to include(:expired, :expire_at)
end end
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册