tests/test-share-safe.t
changeset 45804 b1664f6eb650
parent 45549 68906595016c
child 45805 fd1de908f2b4
--- a/tests/test-share-safe.t	Fri Oct 09 10:33:19 2020 +0200
+++ b/tests/test-share-safe.t	Fri Sep 18 17:28:22 2020 +0530
@@ -81,6 +81,43 @@
   $ hg showconfig ui.curses
   true
 
+Test that extensions of source repository are also loaded
+
+  $ hg debugextensions
+  share
+  $ hg extdiff -p echo
+  hg: unknown command 'extdiff'
+  'extdiff' is provided by the following extension:
+  
+      extdiff       command to allow external programs to compare revisions
+  
+  (use 'hg help extensions' for information on enabling extensions)
+  [255]
+
+  $ echo "[extensions]" >> ../source/.hg/hgrc
+  $ echo "extdiff=" >> ../source/.hg/hgrc
+
+  $ hg debugextensions -R ../source
+  extdiff
+  share
+  $ hg extdiff -R ../source -p echo
+
+BROKEN: the command below does not work but debugextensions says that extension
+is loaded
+  $ hg debugextensions
+  extdiff
+  share
+
+BROKEN: extdiff command should work here
+  $ hg extdiff -p echo
+  hg: unknown command 'extdiff'
+  'extdiff' is provided by the following extension:
+  
+      extdiff       command to allow external programs to compare revisions
+  
+  (use 'hg help extensions' for information on enabling extensions)
+  [255]
+
 However, local .hg/hgrc should override the config set by share source
 
   $ echo "[ui]" >> .hg/hgrc
@@ -92,6 +129,8 @@
   $ HGEDITOR=cat hg config --shared
   [ui]
   curses=true
+  [extensions]
+  extdiff=
 
   $ HGEDITOR=cat hg config --local
   [ui]