mirror of
https://github.com/facebook/sapling.git
synced 2024-10-11 17:27:53 +03:00
mononoke: fix flakiness of test-gettreepack.t
Summary: The reason for flakiness was in unpredictable order of the tree items from Mononoke. In the first gettreepack call we request two different revisions, and Mononoke can return them in any order. hg handles it just fine (see updated test with `hgmn up ...`), but hashes of the tree packs may change. To remove flakiness let's not rely on the treepack files hash Reviewed By: farnz Differential Revision: D7237559 fbshipit-source-id: c04e9d45c41f1d288a90706d0ecc27ede36f8008
This commit is contained in:
parent
7452236c99
commit
4b22e44847
@ -74,12 +74,24 @@ hg prefetch failed for treeonly repos. We can use it instead when it's fixed
|
|||||||
|
|
||||||
Make sure that new entries were downloaded
|
Make sure that new entries were downloaded
|
||||||
$ [[ -a $TESTTMP/cachepath/repo/packs/manifests ]]
|
$ [[ -a $TESTTMP/cachepath/repo/packs/manifests ]]
|
||||||
$ ls $TESTTMP/cachepath/repo/packs/manifests
|
$ ls $TESTTMP/cachepath/repo/packs/manifests | wc -l
|
||||||
14d5757b02d7849c29f5330a9784cde6ea705b10.dataidx
|
8
|
||||||
14d5757b02d7849c29f5330a9784cde6ea705b10.datapack
|
|
||||||
19f8819363e37aac879d4b9d262a6f159c2f499e.histidx
|
Update to the revisions. Make sure that gettreepack command is not sent because
|
||||||
19f8819363e37aac879d4b9d262a6f159c2f499e.histpack
|
we've already downloaded all the trees
|
||||||
2b552b0b3dee8707b0d8e59440602314c30e7c48.histidx
|
$ hgmn up 2 --debug | grep 'sending .* command'
|
||||||
2b552b0b3dee8707b0d8e59440602314c30e7c48.histpack
|
sending hello command
|
||||||
bd34d6c34ee406323fec52573c480997f38ae742.dataidx
|
sending between command
|
||||||
bd34d6c34ee406323fec52573c480997f38ae742.datapack
|
sending getfiles command
|
||||||
|
$ ls
|
||||||
|
A
|
||||||
|
B
|
||||||
|
C
|
||||||
|
|
||||||
|
No wireproto commands should be sent at all, because everything has been already
|
||||||
|
downloaded
|
||||||
|
$ hgmn up 1 --debug | grep 'sending .* command'
|
||||||
|
[1]
|
||||||
|
$ ls
|
||||||
|
A
|
||||||
|
B
|
||||||
|
Loading…
Reference in New Issue
Block a user