braid 1.0.16 → 1.0.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.travis.yml +0 -2
- data/README.md +11 -15
- data/bin/braid +20 -39
- data/braid.gemspec +1 -1
- data/lib/braid/commands/add.rb +0 -3
- data/lib/braid/commands/diff.rb +16 -7
- data/lib/braid/commands/push.rb +4 -0
- data/lib/braid/commands/status.rb +1 -3
- data/lib/braid/commands/update.rb +7 -11
- data/lib/braid/mirror.rb +11 -13
- data/lib/braid/operations.rb +4 -0
- data/lib/braid/version.rb +1 -1
- data/lib/braid.rb +0 -1
- data/spec/config_spec.rb +9 -9
- data/spec/integration/adding_spec.rb +41 -19
- data/spec/integration/diff_spec.rb +185 -0
- data/spec/{integration_helper.rb → integration/integration_helper.rb} +31 -7
- data/spec/integration/push_spec.rb +73 -12
- data/spec/integration/remove_spec.rb +59 -0
- data/spec/integration/status_spec.rb +59 -0
- data/spec/integration/updating_spec.rb +65 -23
- data/spec/mirror_spec.rb +11 -11
- data/spec/operations_spec.rb +8 -8
- metadata +8 -6
- data/lib/braid/commands/list.rb +0 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6b8ca4b2ca46100c1204aa7e8303d29f0ca2f827
|
4
|
+
data.tar.gz: 2762804b4104a9102b215ae04c697607d279667a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d482a938bccaec81fdaf42c058a6d90fc88915335cf46b6a6896e00542850040a3de103026013cb974010389667397393efe1371108afc386f90ed02500b796a
|
7
|
+
data.tar.gz: 7a8eae42c2d2f5d41b6c1f8f18c34d3ee670c5acef87e79c24965a61b71808a16a81d676f00de2dc84ad5725292b046b4b9fe9a0d778d0372e1fa8e3fc52150a
|
data/.travis.yml
CHANGED
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# Braid
|
2
2
|
|
3
3
|
[](http://travis-ci.org/cristibalan/braid)
|
4
|
-
[]()
|
4
|
+
[](https://rubygems.org/gems/braid)
|
5
5
|
|
6
6
|
Braid is a simple tool to help track vendor branches in a
|
7
7
|
[Git](http://git-scm.com/) repository.
|
@@ -35,17 +35,11 @@ repositories and use an automated mechanism for updating the external library
|
|
35
35
|
and generating patches to upgrade the external library.
|
36
36
|
|
37
37
|
Braid creates a file `.braids.json` in the root of your repository that contains
|
38
|
-
references to external libraries or mirrors.
|
39
|
-
|
40
|
-
generally want because they're faster and don't pollute your history with
|
41
|
-
commits from the mirrors.
|
38
|
+
references to external libraries or mirrors. The configuration allows you to control
|
39
|
+
aspects of the mirroring process such as;
|
42
40
|
|
43
|
-
|
44
|
-
|
45
|
-
access to, for example, when using shared code across projects.
|
46
|
-
|
47
|
-
Please note that you cannot change between mirror types after the initial add.
|
48
|
-
You'll have to remove the mirror and add it again.
|
41
|
+
* whether the mirror is locked to a particular version of the external library.
|
42
|
+
* whether the mirror includes the entire external library or just a subdirectory.
|
49
43
|
|
50
44
|
## Installation
|
51
45
|
|
@@ -99,13 +93,15 @@ Use the built in help system to find out about all commands and options:
|
|
99
93
|
|
100
94
|
braid add git://github.com/rails/rails.git vendor/rails
|
101
95
|
|
102
|
-
#### Adding
|
96
|
+
#### Adding a subdirectory from a mirror
|
103
97
|
|
104
|
-
|
98
|
+
This is useful if you want to add a subdirectory from a mirror into your own project.
|
105
99
|
|
106
|
-
|
100
|
+
braid add --path dist https://github.com/twbs/bootstrap.git vendor/assets/bootstrap
|
107
101
|
|
108
|
-
|
102
|
+
#### Adding mirrors with revisions
|
103
|
+
|
104
|
+
braid add --revision bf1b1e0 git://github.com/rails/rails.git vendor/rails
|
109
105
|
|
110
106
|
#### Updating mirrors
|
111
107
|
|
data/bin/braid
CHANGED
@@ -40,11 +40,11 @@ Main {
|
|
40
40
|
. braid add http://remote/path local/dir
|
41
41
|
TXT
|
42
42
|
|
43
|
-
mixin :argument_url, :
|
43
|
+
mixin :argument_url, :optional_local_path, :option_branch, :option_revision, :option_verbose, :option_path
|
44
44
|
|
45
45
|
run {
|
46
46
|
Braid.verbose = verbose
|
47
|
-
Braid::Command.run(:add, url, {'path' =>
|
47
|
+
Braid::Command.run(:add, url, {'path' => local_path, 'branch' => branch, 'revision' => revision, 'remote_path' => path})
|
48
48
|
}
|
49
49
|
}
|
50
50
|
|
@@ -65,7 +65,7 @@ Main {
|
|
65
65
|
. braid update local/dir
|
66
66
|
TXT
|
67
67
|
|
68
|
-
mixin :
|
68
|
+
mixin :optional_local_path, :option_revision, :option_head, :option_verbose, :option_keep_remote
|
69
69
|
|
70
70
|
run {
|
71
71
|
options = {
|
@@ -74,7 +74,7 @@ Main {
|
|
74
74
|
'keep' => keep
|
75
75
|
}
|
76
76
|
Braid.verbose = verbose
|
77
|
-
Braid::Command.run(:update,
|
77
|
+
Braid::Command.run(:update, local_path, options)
|
78
78
|
}
|
79
79
|
}
|
80
80
|
|
@@ -91,14 +91,14 @@ Main {
|
|
91
91
|
. braid remove local/dir
|
92
92
|
TXT
|
93
93
|
|
94
|
-
mixin :
|
94
|
+
mixin :argument_local_path, :option_verbose, :option_keep_remote
|
95
95
|
|
96
96
|
run {
|
97
97
|
options = {
|
98
98
|
:keep => keep
|
99
99
|
}
|
100
100
|
Braid.verbose = verbose
|
101
|
-
Braid::Command.run(:remove,
|
101
|
+
Braid::Command.run(:remove, local_path, options)
|
102
102
|
}
|
103
103
|
}
|
104
104
|
|
@@ -107,14 +107,14 @@ Main {
|
|
107
107
|
Show diff of local changes to mirror.
|
108
108
|
TXT
|
109
109
|
|
110
|
-
mixin :
|
110
|
+
mixin :optional_local_path, :option_verbose, :option_keep_remote
|
111
111
|
|
112
112
|
run {
|
113
113
|
options = {
|
114
114
|
'keep' => keep
|
115
115
|
}
|
116
116
|
Braid.verbose = verbose
|
117
|
-
Braid::Command.run(:diff,
|
117
|
+
Braid::Command.run(:diff, local_path, options)
|
118
118
|
}
|
119
119
|
}
|
120
120
|
|
@@ -123,7 +123,7 @@ Main {
|
|
123
123
|
Push local mirror changes to remote.
|
124
124
|
TXT
|
125
125
|
|
126
|
-
mixin :
|
126
|
+
mixin :argument_local_path, :option_branch, :option_verbose, :option_keep_remote
|
127
127
|
|
128
128
|
run {
|
129
129
|
options = {
|
@@ -131,7 +131,7 @@ Main {
|
|
131
131
|
'branch' => branch
|
132
132
|
}
|
133
133
|
Braid.verbose = verbose
|
134
|
-
Braid::Command.run(:push,
|
134
|
+
Braid::Command.run(:push, local_path, options)
|
135
135
|
}
|
136
136
|
}
|
137
137
|
|
@@ -140,12 +140,12 @@ Main {
|
|
140
140
|
Set up git remotes.
|
141
141
|
TXT
|
142
142
|
|
143
|
-
mixin :
|
143
|
+
mixin :optional_local_path, :option_verbose, :option_force
|
144
144
|
|
145
145
|
run {
|
146
146
|
Braid.verbose = verbose
|
147
147
|
Braid.force = force
|
148
|
-
Braid::Command.run(:setup,
|
148
|
+
Braid::Command.run(:setup, local_path)
|
149
149
|
}
|
150
150
|
}
|
151
151
|
|
@@ -157,36 +157,25 @@ Main {
|
|
157
157
|
}
|
158
158
|
}
|
159
159
|
|
160
|
-
mode(:list) {
|
161
|
-
description 'Show all tracked mirrors (and if updates are available).'
|
162
|
-
|
163
|
-
mixin :option_verbose
|
164
|
-
|
165
|
-
run {
|
166
|
-
Braid.verbose = verbose
|
167
|
-
Braid::Command.run(:list)
|
168
|
-
}
|
169
|
-
}
|
170
|
-
|
171
160
|
mode(:status) {
|
172
161
|
description 'Show the status of all tracked mirrors (and if updates are available).'
|
173
162
|
|
174
|
-
mixin :
|
163
|
+
mixin :optional_local_path, :option_verbose
|
175
164
|
|
176
165
|
run {
|
177
166
|
Braid.verbose = verbose
|
178
|
-
Braid::Command.run(:status,
|
167
|
+
Braid::Command.run(:status, local_path)
|
179
168
|
}
|
180
169
|
}
|
181
170
|
|
182
|
-
mixin(:
|
183
|
-
argument(:
|
171
|
+
mixin(:argument_local_path) {
|
172
|
+
argument(:local_path) {
|
184
173
|
attr
|
185
174
|
}
|
186
175
|
}
|
187
176
|
|
188
|
-
mixin(:
|
189
|
-
argument(:
|
177
|
+
mixin(:optional_local_path) {
|
178
|
+
argument(:local_path) {
|
190
179
|
optional
|
191
180
|
attr
|
192
181
|
}
|
@@ -207,8 +196,8 @@ Main {
|
|
207
196
|
}
|
208
197
|
}
|
209
198
|
|
210
|
-
mixin(:
|
211
|
-
option(:
|
199
|
+
mixin(:option_path) {
|
200
|
+
option(:path, :p) {
|
212
201
|
optional
|
213
202
|
argument :required
|
214
203
|
desc 'remote path'
|
@@ -233,14 +222,6 @@ Main {
|
|
233
222
|
}
|
234
223
|
}
|
235
224
|
|
236
|
-
mixin(:option_full) {
|
237
|
-
option(:full) {
|
238
|
-
optional
|
239
|
-
desc 'include mirror history' # FIXME
|
240
|
-
attr
|
241
|
-
}
|
242
|
-
}
|
243
|
-
|
244
225
|
mixin(:option_verbose) {
|
245
226
|
option(:verbose, :v) {
|
246
227
|
optional
|
data/braid.gemspec
CHANGED
@@ -28,6 +28,6 @@ Gem::Specification.new do |s|
|
|
28
28
|
s.add_dependency(%q<main>, ['>= 4.7.3'])
|
29
29
|
s.add_dependency(%q<open4>, ['>= 1.0.1']) unless defined?(JRUBY_VERSION)
|
30
30
|
|
31
|
-
s.add_development_dependency(%q<rspec>, ['>=
|
31
|
+
s.add_development_dependency(%q<rspec>, ['>= 3.4.4'])
|
32
32
|
s.add_development_dependency(%q<mocha>, ['>= 0.9.11'])
|
33
33
|
end
|
data/lib/braid/commands/add.rb
CHANGED
@@ -19,9 +19,6 @@ module Braid
|
|
19
19
|
new_revision = validate_new_revision(mirror, options['revision'])
|
20
20
|
target_revision = determine_target_revision(mirror, new_revision)
|
21
21
|
|
22
|
-
unless mirror.squashed?
|
23
|
-
git.merge_ours(target_revision)
|
24
|
-
end
|
25
22
|
git.read_tree_prefix_u(target_revision, mirror.path)
|
26
23
|
|
27
24
|
mirror.revision = new_revision
|
data/lib/braid/commands/diff.rb
CHANGED
@@ -8,24 +8,33 @@ module Braid
|
|
8
8
|
protected
|
9
9
|
|
10
10
|
def diff_all(options = {})
|
11
|
-
print "\n"
|
12
|
-
msg "Diffing all mirrors.\n=======================================================\n"
|
13
11
|
config.mirrors.each do |path|
|
14
|
-
|
15
|
-
|
16
|
-
|
12
|
+
separator
|
13
|
+
msg "Diffing #{path}\n"
|
14
|
+
separator
|
15
|
+
diff = perform_diff(path, options)
|
16
|
+
puts diff unless diff.empty?
|
17
17
|
end
|
18
|
-
print "\n"
|
19
18
|
end
|
20
19
|
|
21
20
|
def diff_one(path, options = {})
|
21
|
+
diff = perform_diff(path, options)
|
22
|
+
puts diff unless diff.empty?
|
23
|
+
end
|
24
|
+
|
25
|
+
def separator
|
26
|
+
puts "=======================================================\n"
|
27
|
+
end
|
28
|
+
|
29
|
+
def perform_diff(path, options = {})
|
22
30
|
mirror = config.get!(path)
|
23
31
|
setup_remote(mirror)
|
24
32
|
|
25
33
|
diff = mirror.diff
|
26
|
-
puts diff unless diff.empty?
|
27
34
|
|
28
35
|
clear_remote(mirror, options)
|
36
|
+
|
37
|
+
diff
|
29
38
|
end
|
30
39
|
end
|
31
40
|
end
|
data/lib/braid/commands/push.rb
CHANGED
@@ -34,9 +34,13 @@ module Braid
|
|
34
34
|
elsif File.directory?(remote_url)
|
35
35
|
remote_url = File.expand_path(remote_url)
|
36
36
|
end
|
37
|
+
user_name = git.config(%w(--local --get user.name))
|
38
|
+
user_email = git.config(%w(--local --get user.email))
|
37
39
|
Dir.chdir(clone_dir) do
|
38
40
|
msg 'Cloning mirror with local changes.'
|
39
41
|
git.init
|
42
|
+
git.config(['--local', 'user.name', "\"#{user_name}\""]) if user_name
|
43
|
+
git.config(['--local', 'user.email', "\"#{user_email}\""]) if user_email
|
40
44
|
git.fetch(mirror.cached_url) if File.exist?(mirror.cached_url)
|
41
45
|
git.fetch(remote_url, "+refs/heads/#{mirror.branch}")
|
42
46
|
git.checkout(base_revision)
|
@@ -55,7 +55,7 @@ module Braid
|
|
55
55
|
return
|
56
56
|
end
|
57
57
|
|
58
|
-
base_revision = mirror.base_revision
|
58
|
+
base_revision = mirror.base_revision
|
59
59
|
|
60
60
|
mirror.revision = new_revision
|
61
61
|
mirror.lock = new_revision if options['revision']
|
@@ -63,16 +63,12 @@ module Braid
|
|
63
63
|
msg "Merging in mirror '#{mirror.path}'." if verbose?
|
64
64
|
in_error = false
|
65
65
|
begin
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
git.merge_trees(base_hash, local_hash, remote_hash)
|
73
|
-
else
|
74
|
-
git.merge_subtree(target_revision)
|
75
|
-
end
|
66
|
+
local_hash = git.rev_parse('HEAD')
|
67
|
+
base_hash = generate_tree_hash(mirror, mirror.versioned_path(base_revision))
|
68
|
+
remote_hash = generate_tree_hash(mirror, target_revision)
|
69
|
+
ENV["GITHEAD_#{local_hash}"] = 'HEAD'
|
70
|
+
ENV["GITHEAD_#{remote_hash}"] = target_revision
|
71
|
+
git.merge_trees(base_hash, local_hash, remote_hash)
|
76
72
|
rescue Operations::MergeError => error
|
77
73
|
in_error = true
|
78
74
|
print error.conflicts_text
|
data/lib/braid/mirror.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
module Braid
|
2
2
|
class Mirror
|
3
|
-
ATTRIBUTES = %w(url branch
|
3
|
+
ATTRIBUTES = %w(url branch revision lock path)
|
4
4
|
|
5
5
|
class UnknownType < BraidError
|
6
6
|
def message
|
@@ -30,11 +30,9 @@ module Braid
|
|
30
30
|
path = (options['path'] || extract_path_from_url(url)).sub(/\/$/, '')
|
31
31
|
raise PathRequired unless path
|
32
32
|
|
33
|
-
squashed = !options['full']
|
34
|
-
|
35
33
|
remote_path = options['remote_path']
|
36
34
|
|
37
|
-
attributes = {'url' => url, 'branch' => branch, '
|
35
|
+
attributes = {'url' => url, 'branch' => branch, 'path' => remote_path}
|
38
36
|
self.new(path, attributes)
|
39
37
|
end
|
40
38
|
|
@@ -46,19 +44,11 @@ module Braid
|
|
46
44
|
!!lock
|
47
45
|
end
|
48
46
|
|
49
|
-
def squashed?
|
50
|
-
!!squashed
|
51
|
-
end
|
52
|
-
|
53
47
|
def merged?(commit)
|
54
48
|
# tip from spearce in #git:
|
55
49
|
# `test z$(git merge-base A B) = z$(git rev-parse --verify A)`
|
56
50
|
commit = git.rev_parse(commit)
|
57
|
-
|
58
|
-
!!base_revision && git.merge_base(commit, base_revision) == commit
|
59
|
-
else
|
60
|
-
git.merge_base(commit, 'HEAD') == commit
|
61
|
-
end
|
51
|
+
!!base_revision && git.merge_base(commit, base_revision) == commit
|
62
52
|
end
|
63
53
|
|
64
54
|
def versioned_path(revision)
|
@@ -89,6 +79,14 @@ module Braid
|
|
89
79
|
end
|
90
80
|
end
|
91
81
|
|
82
|
+
def remote_path
|
83
|
+
self.attributes['path']
|
84
|
+
end
|
85
|
+
|
86
|
+
def remote_path=(remote_path)
|
87
|
+
self.attributes['path'] = remote_path
|
88
|
+
end
|
89
|
+
|
92
90
|
def cached_url
|
93
91
|
git_cache.path(url)
|
94
92
|
end
|
data/lib/braid/operations.rb
CHANGED
data/lib/braid/version.rb
CHANGED
data/lib/braid.rb
CHANGED
data/spec/config_spec.rb
CHANGED
@@ -10,14 +10,14 @@ describe 'Braid::Config, when empty' do
|
|
10
10
|
end
|
11
11
|
|
12
12
|
it 'should not get a mirror by name' do
|
13
|
-
@config.get('path').
|
14
|
-
|
13
|
+
expect(@config.get('path')).to be_nil
|
14
|
+
expect { @config.get!('path') }.to raise_error(Braid::Config::MirrorDoesNotExist)
|
15
15
|
end
|
16
16
|
|
17
17
|
it 'should add a mirror and its params' do
|
18
18
|
@mirror = build_mirror
|
19
19
|
@config.add(@mirror)
|
20
|
-
@config.get('path').path.
|
20
|
+
expect(@config.get('path').path).not_to be_nil
|
21
21
|
end
|
22
22
|
end
|
23
23
|
|
@@ -33,27 +33,27 @@ describe 'Braid::Config, with one mirror' do
|
|
33
33
|
end
|
34
34
|
|
35
35
|
it 'should get the mirror by name' do
|
36
|
-
@config.get('path').
|
37
|
-
@config.get!('path').
|
36
|
+
expect(@config.get('path')).to eq(@mirror)
|
37
|
+
expect(@config.get!('path')).to eq(@mirror)
|
38
38
|
end
|
39
39
|
|
40
40
|
it 'should raise when trying to overwrite a mirror on add' do
|
41
|
-
|
41
|
+
expect { @config.add(@mirror) }.to raise_error(Braid::Config::PathAlreadyInUse)
|
42
42
|
end
|
43
43
|
|
44
44
|
it 'should remove the mirror' do
|
45
45
|
@config.remove(@mirror)
|
46
|
-
@config.get('path').
|
46
|
+
expect(@config.get('path')).to be_nil
|
47
47
|
end
|
48
48
|
|
49
49
|
it 'should update the mirror with new params' do
|
50
50
|
@mirror.branch = 'other'
|
51
51
|
@config.update(@mirror)
|
52
|
-
@config.get('path').attributes.
|
52
|
+
expect(@config.get('path').attributes).to eq({'branch' => 'other'})
|
53
53
|
end
|
54
54
|
|
55
55
|
it 'should raise when trying to update nonexistent mirror' do
|
56
56
|
@mirror.instance_variable_set('@path', 'other')
|
57
|
-
|
57
|
+
expect { @config.update(@mirror) }.to raise_error(Braid::Config::MirrorDoesNotExist)
|
58
58
|
end
|
59
59
|
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.dirname(__FILE__) + '
|
1
|
+
require File.dirname(__FILE__) + '/integration_helper'
|
2
2
|
|
3
3
|
describe 'Adding a mirror in a clean repository' do
|
4
4
|
|
@@ -9,33 +9,55 @@ describe 'Adding a mirror in a clean repository' do
|
|
9
9
|
|
10
10
|
describe 'from a git repository' do
|
11
11
|
before do
|
12
|
-
@
|
13
|
-
@
|
14
|
-
end
|
12
|
+
@repository_dir = create_git_repo_from_fixture('shiny', :name => 'Some body', :email => 'somebody@example.com')
|
13
|
+
@vendor_repository_dir = create_git_repo_from_fixture('skit1')
|
15
14
|
|
16
|
-
|
17
|
-
|
18
|
-
run_command("#{BRAID_BIN} add #{@skit1}")
|
15
|
+
in_dir(@repository_dir) do
|
16
|
+
run_command("#{BRAID_BIN} add #{@vendor_repository_dir}")
|
19
17
|
end
|
18
|
+
end
|
20
19
|
|
21
|
-
|
22
|
-
|
20
|
+
it 'should add the files and commit' do
|
21
|
+
assert_no_diff("#{FIXTURE_PATH}/skit1/layouts/layout.liquid", "#{@repository_dir}/skit1/layouts/layout.liquid")
|
23
22
|
|
24
|
-
|
25
|
-
|
26
|
-
|
23
|
+
assert_commit_subject(/Braid: Add mirror 'skit1' at '[0-9a-f]{7}'/)
|
24
|
+
assert_commit_author('Some body')
|
25
|
+
assert_commit_email('somebody@example.com')
|
27
26
|
end
|
28
27
|
|
29
28
|
it 'should create .braids.json and add the mirror to it' do
|
30
|
-
|
31
|
-
|
29
|
+
braids = YAML::load_file("#{@repository_dir}/.braids.json")
|
30
|
+
expect(braids['skit1']['url']).to eq(@vendor_repository_dir)
|
31
|
+
expect(braids['skit1']['revision']).not_to be_nil
|
32
|
+
expect(braids['skit1']['branch']).to eq('master')
|
33
|
+
expect(braids['skit1']['path']).to be_nil
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
37
|
+
describe 'from a subdirectory in a git repository' do
|
38
|
+
before do
|
39
|
+
@repository_dir = create_git_repo_from_fixture('shiny', :name => 'Some body', :email => 'somebody@example.com')
|
40
|
+
@vendor_repository_dir = create_git_repo_from_fixture('skit1')
|
41
|
+
|
42
|
+
in_dir(@repository_dir) do
|
43
|
+
run_command("#{BRAID_BIN} add --path layouts #{@vendor_repository_dir}")
|
32
44
|
end
|
45
|
+
end
|
46
|
+
|
47
|
+
it 'should add the files and commit' do
|
48
|
+
assert_no_diff("#{FIXTURE_PATH}/skit1/layouts/layout.liquid", "#{@repository_dir}/skit1/layout.liquid")
|
33
49
|
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
50
|
+
assert_commit_subject(/Braid: Add mirror 'skit1' at '[0-9a-f]{7}'/)
|
51
|
+
assert_commit_author('Some body')
|
52
|
+
assert_commit_email('somebody@example.com')
|
53
|
+
end
|
54
|
+
|
55
|
+
it 'should create .braids.json and add the mirror to it' do
|
56
|
+
braids = YAML::load_file("#{@repository_dir}/.braids.json")
|
57
|
+
expect(braids['skit1']['url']).to eq(@vendor_repository_dir)
|
58
|
+
expect(braids['skit1']['revision']).not_to be_nil
|
59
|
+
expect(braids['skit1']['branch']).to eq('master')
|
60
|
+
expect(braids['skit1']['path']).to eq('layouts')
|
39
61
|
end
|
40
62
|
end
|
41
63
|
end
|