mirror of
https://github.com/pcottle/learnGitBranching.git
synced 2025-07-12 23:54:27 +02:00
now rebase coverage
This commit is contained in:
parent
cb47dd2728
commit
6a48f2fff4
4 changed files with 18 additions and 4 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -2,4 +2,5 @@ node_modules/
|
||||||
screens
|
screens
|
||||||
search_replace.sh
|
search_replace.sh
|
||||||
FontAwesome-Vectors.pdf
|
FontAwesome-Vectors.pdf
|
||||||
|
*.sw*
|
||||||
|
|
||||||
|
|
|
@ -44,8 +44,6 @@ describe('Mercurial', function() {
|
||||||
'%7B%22branches%22%3A%7B%22master%22%3A%7B%22target%22%3A%22C2%27%22%2C%22id%22%3A%22master%22%7D%7D%2C%22commits%22%3A%7B%22C0%22%3A%7B%22parents%22%3A%5B%5D%2C%22id%22%3A%22C0%22%2C%22rootCommit%22%3Atrue%7D%2C%22C1%22%3A%7B%22parents%22%3A%5B%22C0%22%5D%2C%22id%22%3A%22C1%22%7D%2C%22C2%22%3A%7B%22parents%22%3A%5B%22C1%22%5D%2C%22id%22%3A%22C2%22%7D%2C%22C2%27%22%3A%7B%22parents%22%3A%5B%22C1%22%5D%2C%22id%22%3A%22C2%27%22%7D%7D%2C%22HEAD%22%3A%7B%22target%22%3A%22master%22%2C%22id%22%3A%22HEAD%22%7D%7D'
|
'%7B%22branches%22%3A%7B%22master%22%3A%7B%22target%22%3A%22C2%27%22%2C%22id%22%3A%22master%22%7D%7D%2C%22commits%22%3A%7B%22C0%22%3A%7B%22parents%22%3A%5B%5D%2C%22id%22%3A%22C0%22%2C%22rootCommit%22%3Atrue%7D%2C%22C1%22%3A%7B%22parents%22%3A%5B%22C0%22%5D%2C%22id%22%3A%22C1%22%7D%2C%22C2%22%3A%7B%22parents%22%3A%5B%22C1%22%5D%2C%22id%22%3A%22C2%22%7D%2C%22C2%27%22%3A%7B%22parents%22%3A%5B%22C1%22%5D%2C%22id%22%3A%22C2%27%22%7D%7D%2C%22HEAD%22%3A%7B%22target%22%3A%22master%22%2C%22id%22%3A%22HEAD%22%7D%7D'
|
||||||
);
|
);
|
||||||
|
|
||||||
return;
|
|
||||||
// TODO -- need to shim out more animation factory things
|
|
||||||
assert(
|
assert(
|
||||||
'rebases with -d',
|
'rebases with -d',
|
||||||
'hg ci; hg book -r C1 feature; hg update feature; hg ci;hg book debug;hg ci;hg rebase -d master;',
|
'hg ci; hg book -r C1 feature; hg update feature; hg ci;hg book debug;hg ci;hg rebase -d master;',
|
||||||
|
|
|
@ -2383,8 +2383,19 @@ var Commit = Backbone.Model.extend({
|
||||||
this.removeFromParents();
|
this.removeFromParents();
|
||||||
this.set('parents', [newParent]);
|
this.set('parents', [newParent]);
|
||||||
newParent.get('children').push(this);
|
newParent.get('children').push(this);
|
||||||
this.get('visNode').removeAllEdges();
|
|
||||||
this.get('gitVisuals').addEdge(this.get('id'), newestID);
|
// when we run in test mode, our visnode and
|
||||||
|
// visuals will be undefined so we need to check for their existence
|
||||||
|
var visNode = this.get('visNode');
|
||||||
|
if (visNode) {
|
||||||
|
visNode.removeAllEdges();
|
||||||
|
}
|
||||||
|
|
||||||
|
var gitVisuals = this.get('gitVisuals');
|
||||||
|
if (gitVisuals) {
|
||||||
|
gitVisuals.addEdge(this.get('id'), newestID);
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -45,6 +45,10 @@ var AnimationQueue = Backbone.Model.extend({
|
||||||
promise.then(_.bind(function() {
|
promise.then(_.bind(function() {
|
||||||
this.finish();
|
this.finish();
|
||||||
}, this));
|
}, this));
|
||||||
|
promise.fail(function(e) {
|
||||||
|
console.log('uncaught error', e);
|
||||||
|
throw e;
|
||||||
|
});
|
||||||
this.set('promiseBased', true);
|
this.set('promiseBased', true);
|
||||||
if (deferred) {
|
if (deferred) {
|
||||||
deferred.resolve();
|
deferred.resolve();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue