|
85 | 85 | it 'should produce log messages indicating the dirctory is being cached' do |
86 | 86 | expect(@result[:logs]).to match(/Begin bootstrap cached master directory/) |
87 | 87 | expect(@result[:logs]).to match(/Success bootstrap cached master directory/) |
88 | | - expect(@result[:logs]).to match(/Cached master directory bootstrapped to 948b3874f5af7f91a5f370e306731fec048fa62e/) |
| 88 | + expect(@result[:logs]).to match(/Cached master directory bootstrapped to ff1928f3f8d9295c3f26b1de70977ed3eea9329e/) |
89 | 89 | expect(@result[:logs]).to match(/Cached master catalog for rspec-node.github.net/) |
90 | 90 | end |
91 | 91 |
|
92 | 92 | it 'should store the SHA in the cached directory' do |
93 | 93 | sha_file = File.join(@cached_master_dir, '.catalog-diff-master.sha') |
94 | 94 | expect(File.file?(sha_file)).to eq(true), `ls -lRa "#{@cached_master_dir}"` |
95 | | - expect(File.read(sha_file)).to eq('948b3874f5af7f91a5f370e306731fec048fa62e') |
| 95 | + expect(File.read(sha_file)).to eq('ff1928f3f8d9295c3f26b1de70977ed3eea9329e') |
96 | 96 | end |
97 | 97 |
|
98 | 98 | it 'should store the catalog in the cached directory' do |
|
130 | 130 | expect(result[:diffs].size).to eq(5) |
131 | 131 |
|
132 | 132 | # Examine log messages to ensure that cached catalog was used |
133 | | - expect(result[:logs]).to match(/Cached master dir: bootstrapped=948b3\w+; current=948b3874f5af7f91a5f370e30\w+/) |
| 133 | + expect(result[:logs]).to match(/Cached master dir: bootstrapped=ff192\w+; current=ff1928f3f8d9295c3f26b1de7\w+/) |
134 | 134 | expect(result[:logs]).to match(/Setting --bootstrapped-from-dir=/) |
135 | 135 | expect(result[:logs]).to match(%r{Setting --from-catalog=.*/.catalogs/rspec-node.github.net.json}) |
136 | 136 | expect(result[:logs]).to match(/Initialized OctocatalogDiff::Catalog::JSON for from-catalog/) |
|
167 | 167 | expect(result[:exitcode]).to eq(-1) |
168 | 168 | expect(result[:exception]).to be_a_kind_of(Errno::EEXIST) |
169 | 169 | expect(result[:exception].message).to match(/To proceed, .* needs to be deleted, so it can be re-created/) |
170 | | - expect(result[:logs]).to match(/bootstrapped=asdlfkjadfsklj; current=948b3874f5af7f91a5f370e306731fec048fa62e/) |
| 170 | + expect(result[:logs]).to match(/bootstrapped=asdlfkjadfsklj; current=ff1928f3f8d9295c3f26b1de70977ed3eea9329e/) |
171 | 171 | end |
172 | 172 |
|
173 | 173 | it 'should rebuild the cached catalog when the sha changes' do |
|
208 | 208 | expect(result[:diffs].size).to eq(5) |
209 | 209 |
|
210 | 210 | # Examine log messages to ensure that cached catalog was not used |
211 | | - expect(result[:logs]).to match(/Cached master dir: bootstrapped=asdlfkjadfsklj; current=948b3874f5af7/) |
| 211 | + expect(result[:logs]).to match(/Cached master dir: bootstrapped=asdlfkjadfsklj; current=ff1928f3f8d92/) |
212 | 212 | expect(result[:logs]).not_to match(%r{Setting --from-catalog=.*/.catalogs/rspec-node.github.net.json}) |
213 | 213 | expect(result[:logs]).to match(/Success build_catalog for test-branch/) |
214 | 214 | expect(result[:logs]).to match(/Success build_catalog for master/) |
215 | | - expect(result[:logs]).to match(/Cached master directory bootstrapped to 948b3874f5af7f91a5f370e306731fec048fa62e/) |
| 215 | + expect(result[:logs]).to match(/Cached master directory bootstrapped to ff1928f3f8d9295c3f26b1de70977ed3eea9329e/) |
216 | 216 |
|
217 | 217 | # Make sure the flag file got removed |
218 | 218 | expect(File.file?(File.join(@cached_master_dir, '.flag'))).to eq(false) |
|
0 commit comments