|
183 | 183 | gem "myrack" |
184 | 184 | G |
185 | 185 |
|
186 | | - versions = Pathname.new(Bundler.rubygems.user_home).join( |
187 | | - ".bundle", "cache", "compact_index", |
| 186 | + versions = compact_index_cache_path.join( |
188 | 187 | "localgemserver.test.80.dd34752a738ee965a2a4298dc16db6c5", "versions" |
189 | 188 | ) |
190 | 189 | versions.dirname.mkpath |
@@ -789,8 +788,7 @@ def start |
789 | 788 | end |
790 | 789 |
|
791 | 790 | it "performs update with etag not-modified" do |
792 | | - versions_etag = Pathname.new(Bundler.rubygems.user_home).join( |
793 | | - ".bundle", "cache", "compact_index", |
| 791 | + versions_etag = compact_index_cache_path.join( |
794 | 792 | "localgemserver.test.80.dd34752a738ee965a2a4298dc16db6c5", "versions.etag" |
795 | 793 | ) |
796 | 794 | expect(versions_etag.file?).to eq(false) |
@@ -833,8 +831,7 @@ def start |
833 | 831 | gem 'myrack', '1.0.0' |
834 | 832 | G |
835 | 833 |
|
836 | | - versions = Pathname.new(Bundler.rubygems.user_home).join( |
837 | | - ".bundle", "cache", "compact_index", |
| 834 | + versions = compact_index_cache_path.join( |
838 | 835 | "localgemserver.test.80.dd34752a738ee965a2a4298dc16db6c5", "versions" |
839 | 836 | ) |
840 | 837 | # Modify the cached file. The ranged request will be based on this but, |
@@ -876,8 +873,7 @@ def start |
876 | 873 | G |
877 | 874 |
|
878 | 875 | # Create a partial cache versions file |
879 | | - versions = Pathname.new(Bundler.rubygems.user_home).join( |
880 | | - ".bundle", "cache", "compact_index", |
| 876 | + versions = compact_index_cache_path.join( |
881 | 877 | "localgemserver.test.80.dd34752a738ee965a2a4298dc16db6c5", "versions" |
882 | 878 | ) |
883 | 879 | versions.dirname.mkpath |
@@ -941,7 +937,7 @@ def start |
941 | 937 |
|
942 | 938 | bundle :install, artifice: "compact_index" |
943 | 939 |
|
944 | | - cache_path = File.join(Bundler.rubygems.user_home, ".bundle", "cache", "compact_index", "localgemserver.test.80.dd34752a738ee965a2a4298dc16db6c5") |
| 940 | + cache_path = compact_index_cache_path.join("localgemserver.test.80.dd34752a738ee965a2a4298dc16db6c5") |
945 | 941 |
|
946 | 942 | # We must remove the etag so that we don't ignore the range and get a 304 Not Modified. |
947 | 943 | myrack_info_etag_path = File.join(cache_path, "info-etags", "myrack-92f3313ce5721296f14445c3a6b9c073") |
|
0 commit comments