Blame view

tests/.zshenv 1.14 KB
d91893a12   Shrikant Sharat   Initial stuff. Th...
1
2
3
  # zshrc file written for antigen's tests. Might not be a good one for daily use.
  
  # See cram's documentation for some of the variables used below.
e0d9ad45a   Shrikant Sharat   Fix #9 Add test f...
4
  export ADOTDIR="$PWD/dot-antigen"
d91893a12   Shrikant Sharat   Initial stuff. Th...
5

27ff756cd   Shrikant Sharat   Remove the `.zcom...
6
  test -f "$TESTDIR/.zcompdump" && rm "$TESTDIR/.zcompdump"
d91893a12   Shrikant Sharat   Initial stuff. Th...
7
8
  
  source "$TESTDIR/../antigen.zsh"
e97637cd0   Shrikant Sharat   Moved common code...
9
10
  
  # A test plugin repository to test out antigen with.
293eecb90   Shrikant Sharat   Remove hard coded...
11
12
  export PLUGIN_DIR="$PWD/test-plugin"
  mkdir "$PLUGIN_DIR"
e97637cd0   Shrikant Sharat   Moved common code...
13
14
  
  # A wrapper function over `git` to work with the test plugin repo.
80d6fbe60   Shrikant Sharat   Add another test ...
15
  alias pg='git --git-dir "$PLUGIN_DIR/.git" --work-tree "$PLUGIN_DIR"'
e97637cd0   Shrikant Sharat   Moved common code...
16

80d6fbe60   Shrikant Sharat   Add another test ...
17
  echo 'alias hehe="echo hehe"' > "$PLUGIN_DIR"/aliases.zsh
0c257ebe4   Shrikant Sharat   For #29. Intial w...
18
  echo 'export PS1="prompt>"' > "$PLUGIN_DIR"/silly.zsh-theme
e97637cd0   Shrikant Sharat   Moved common code...
19
20
21
22
23
24
  
  {
      pg init
      pg add .
      pg commit -m 'Initial commit'
  } > /dev/null
80d6fbe60   Shrikant Sharat   Add another test ...
25
26
27
28
29
30
31
32
  
  # Another test plugin.
  
  export PLUGIN_DIR2="$PWD/test-plugin2"
  mkdir "$PLUGIN_DIR2"
  
  # A wrapper function over `git` to work with the test plugin repo.
  alias pg2='git --git-dir "$PLUGIN_DIR2/.git" --work-tree "$PLUGIN_DIR2"'
e8a2b3a63   Shrikant Sharat   Added tests for l...
33
34
  echo 'alias hehe2="echo hehe2"' > "$PLUGIN_DIR2"/init.zsh
  echo 'alias unsourced-alias="echo unsourced-alias"' > "$PLUGIN_DIR2"/aliases.zsh
80d6fbe60   Shrikant Sharat   Add another test ...
35
36
37
38
39
40
  
  {
      pg2 init
      pg2 add .
      pg2 commit -m 'Initial commit'
  } > /dev/null