dorawyy / git-merge-conflicts-test

This repo is for testing of git functionalities / different merging conflict scenarios, and CI tools usage
2 stars 4 forks source link

[testcase notes] #29: Git merge categorization #75

Open dorawyy opened 6 years ago

dorawyy commented 6 years ago

git merge Categorization

Intro of different options --> #64

Fast-forward Merge

fast-forward-merge

Three-way Merge

three-way-merge

dorawyy commented 6 years ago

Three-way Merge

Three-way merge with single conflict

git checkout mt3
git merge mt4

1

git checkout mt3
git merge mt4 --no-commit

2

git checkout mt3
git merge mt4 --squash

3

Additional test: if commit6 created a new file, not existing in mt3 after commit5:

4

dorawyy commented 6 years ago

Three-way merge with no conflict

git checkout mt1
git merge mt2 

wechatimg325

git checkout mt1
git merge mt2 --no-commit

wechatimg326

git checkout mt1
git merge mt2 --squash

wechatimg327

Additional test: If commit6 happens after commit5, then merge; No matter what merge option (normal/squash/no-commit) file in commit6 will always be seen bymt1.

wechatimg328