When any change is made to the XPATH within the Object file, the corresponding .rs file generates random Guids in the tag.
Using GIT, this can be a problem. Because if this code is different for each user, there will be conflicts. Even resolving the conflicts, the id in the tag in the .rs file are unique for each computer/project.
And if the tag is changed, the object simply disappears from the Object Repository folder and the reference is lost, but .rs file continues to exist in the windows folder.
How to solve this problem?
I doubt this.
I did a quick check. I read an rs file of a Test object with XPath
I changed the XPath to
//section[@id='summary']/div/div/div/p/span, and the
<elementGuidId> was still
If you believe you are telling a fact, please prove it with more detai information (screenshot etc).
Thanks, I could reproduce what you mean. Yes, the value of
<webElementGuid> is changed when the XPath is changed.
Still I do not understand your argument that changing UUID causes problem in using Git. But I am tired already 'cause late at night. Bye.
The problem is when user A and user B commit at the same time on the same file.
The second will need to resolve the conflict.
If you accept the changes from the last PULL, the object loses reference and disappears from the Katalon Object Repository.
That is not a “problem”. It tends to happen when 2 or more people share a remote Git repository. User A and B must be well-trained for Git and should be able to avoid conflicts proactively = they should always do PULL before commitiing. And they must be well-trained for Git so that they are capable of resolving the conflicts if they got any.
Git wil change files on disk, but does Katalon automatically refleshes the GUI when a user did “git pull” by Katalon’s menu? I just gess, Katalon doesn’t. I think thatKatalon Studio never reflshes its GUI from the lastest files on disk automatically when Git wrote something into disk.
In that case, when you did git pull by commandl ine you need to reflesh Katalon GUI from disk intentionally. Have you ever tried closing the project and reopen it so that the view is refreshed from the disk? Or stop & restart Katalon Studio entirely? I guess that the Test Object will re-appear in the Object Repository tree in the Test Explorer after refreshing from disk
This is why, user A and user B should work on separate working branches.
So, provided user A has already comited and merged his changes to the development branch, when user B attempts to do the same will get a merge conflict.
Therefore, user B must rebase his branch to solve the conflicts and push again.
The same principle apply if forking is used instead of branching
(altough I do not recommend this method when working on the same company / same project.
forking is more suitable when working on different projects but using a certain common code base, e.g this is the preffered model for various linux distributions forks/spins developped by different comunities)
User B should fetch the upstream changes before comitting and open his PR.
This is how git works.