Improve docs and specs related to pages artifacts
This commit is contained in:
parent
098a876f93
commit
8f227f23a7
|
@ -134,7 +134,7 @@ configuration for our example. On the steps below, we'll refine
|
||||||
the script by adding extra options to our GitLab CI.
|
the script by adding extra options to our GitLab CI.
|
||||||
|
|
||||||
Artifacts will be automatically deleted once GitLab Pages got deployed.
|
Artifacts will be automatically deleted once GitLab Pages got deployed.
|
||||||
You can preserve artifacts for limited time by specifying expiry time.
|
You can preserve artifacts for limited time by specifying the expiry time.
|
||||||
|
|
||||||
### Image
|
### Image
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,7 @@ describe Projects::UpdatePagesService do
|
||||||
build.update_attributes(artifacts_metadata: metadata)
|
build.update_attributes(artifacts_metadata: metadata)
|
||||||
end
|
end
|
||||||
|
|
||||||
context 'artifacts' do
|
describe 'pages artifacts' do
|
||||||
context 'with expiry date' do
|
context 'with expiry date' do
|
||||||
before do
|
before do
|
||||||
build.artifacts_expire_in = "2 days"
|
build.artifacts_expire_in = "2 days"
|
||||||
|
@ -34,6 +34,7 @@ describe Projects::UpdatePagesService do
|
||||||
|
|
||||||
it "doesn't delete artifacts" do
|
it "doesn't delete artifacts" do
|
||||||
expect(execute).to eq(:success)
|
expect(execute).to eq(:success)
|
||||||
|
|
||||||
expect(build.reload.artifacts_file?).to eq(true)
|
expect(build.reload.artifacts_file?).to eq(true)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -41,6 +42,7 @@ describe Projects::UpdatePagesService do
|
||||||
context 'without expiry date' do
|
context 'without expiry date' do
|
||||||
it "does delete artifacts" do
|
it "does delete artifacts" do
|
||||||
expect(execute).to eq(:success)
|
expect(execute).to eq(:success)
|
||||||
|
|
||||||
expect(build.reload.artifacts_file?).to eq(false)
|
expect(build.reload.artifacts_file?).to eq(false)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue