cocoapods-repo-update 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/cocoapods_repo_update/gem_version.rb +1 -1
- data/lib/cocoapods_repo_update/hooks.rb +4 -3
- data/spec/unit/hooks_spec.rb +2 -5
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 779accb52ea1d9cb5caff2e957c08b06c49cbc32
|
4
|
+
data.tar.gz: e2cbc0bf417319b834422cad6542eaa0a932edd8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5709266e33abf96ee2f14ece070ee095b1bdb6641bc757acdc70a1a46896e71a42ccc481a2d7df0855702b8a172c4229de82f8d3bf645f01c53adb8ced38c167
|
7
|
+
data.tar.gz: d4b1775cf7afd57d29ba84c4daa461c2db0e199372b071bc7762769a180b9f02f8aa30994dc798d6e36775d75831d7bb869a3f8349c6adfc065abc9c6e9e16bc
|
@@ -18,9 +18,10 @@ module CocoapodsRepoUpdate
|
|
18
18
|
Pod::UI.puts "Not updating local specs repo"
|
19
19
|
rescue Pod::NoSpecFoundError
|
20
20
|
Pod::UI.puts "At least one Pod is not in the local specs repo. Updating specs repo..."
|
21
|
-
|
22
|
-
|
23
|
-
|
21
|
+
# Update the specs repos, silently
|
22
|
+
CocoapodsRepoUpdate::Helper.suppress_output do
|
23
|
+
analyzer.update_repositories
|
24
|
+
end
|
24
25
|
end
|
25
26
|
end
|
26
27
|
end
|
data/spec/unit/hooks_spec.rb
CHANGED
@@ -12,27 +12,24 @@ describe CocoapodsRepoUpdate::Hooks do
|
|
12
12
|
podfile: double('podfile'),
|
13
13
|
lockfile: double('lockfile')) }
|
14
14
|
let(:analyzer) { double('analyzer') }
|
15
|
-
let(:sources_manager) { double('sources manager') }
|
16
|
-
let(:config) { double('config', sources_manager: sources_manager) }
|
17
15
|
|
18
16
|
before do
|
19
17
|
allow(Pod::Installer::Analyzer).to receive(:new).with(installer_context.sandbox,
|
20
18
|
installer_context.podfile,
|
21
19
|
installer_context.lockfile).and_return(analyzer)
|
22
|
-
allow(Pod::Config).to receive(:new).and_return(config)
|
23
20
|
end
|
24
21
|
|
25
22
|
context 'pre install' do
|
26
23
|
it 'runs the post install action without updating specs' do
|
27
24
|
allow(analyzer).to receive(:analyze)
|
28
|
-
expect(
|
25
|
+
expect(analyzer).not_to receive(:update_repositories)
|
29
26
|
|
30
27
|
trigger_pre_install(installer_context, options)
|
31
28
|
end
|
32
29
|
|
33
30
|
it 'runs the post install action and updates specs' do
|
34
31
|
allow(analyzer).to receive(:analyze).and_raise(Pod::NoSpecFoundError)
|
35
|
-
expect(
|
32
|
+
expect(analyzer).to receive(:update_repositories)
|
36
33
|
|
37
34
|
trigger_pre_install(installer_context, options)
|
38
35
|
end
|