@@ -52,13 +52,14 @@ func TestResolveDotfiles(t *testing.T) {
5252 "machines/server/blank.ovrd" ,
5353 "machines/desktop/multi-composed" ,
5454 },
55- ExistingFiles : []string {},
55+ ExistingFiles : []string {"bash/conf" , "environment" },
5656 Groups : []string {"base" , "machines/desktop" , "machines/server" },
5757 OverrideSuffix : "ovrd" ,
5858 InstallSuffix : "inst" ,
5959 Expected : Dotfiles {
6060 {
61- Path : "bash/conf" ,
61+ Path : "bash/conf" ,
62+ Added : false ,
6263 Sources : []* SourceFile {
6364 {
6465 Group : "base" ,
@@ -68,7 +69,8 @@ func TestResolveDotfiles(t *testing.T) {
6869 InstallFiles : []string {"base/bash.inst" },
6970 },
7071 {
71- Path : "bash/conf2" ,
72+ Path : "bash/conf2" ,
73+ Added : true ,
7274 Sources : []* SourceFile {
7375 {
7476 Group : "base" ,
@@ -78,7 +80,8 @@ func TestResolveDotfiles(t *testing.T) {
7880 InstallFiles : []string {"base/bash.inst" },
7981 },
8082 {
81- Path : "blank" ,
83+ Path : "blank" ,
84+ Added : true ,
8285 Sources : []* SourceFile {
8386 {
8487 Group : "machines/server" ,
@@ -88,7 +91,8 @@ func TestResolveDotfiles(t *testing.T) {
8891 },
8992 },
9093 {
91- Path : "environment" ,
94+ Path : "environment" ,
95+ Added : false ,
9296 Sources : []* SourceFile {
9397 {
9498 Group : "base" ,
@@ -101,7 +105,8 @@ func TestResolveDotfiles(t *testing.T) {
101105 },
102106 },
103107 {
104- Path : "generic-config" ,
108+ Path : "generic-config" ,
109+ Added : true ,
105110 Sources : []* SourceFile {
106111 {
107112 Group : "base" ,
@@ -116,7 +121,8 @@ func TestResolveDotfiles(t *testing.T) {
116121 InstallFiles : []string {"base/generic-config.inst" },
117122 },
118123 {
119- Path : "multi-composed" ,
124+ Path : "multi-composed" ,
125+ Added : true ,
120126 Sources : []* SourceFile {
121127 {
122128 Group : "base" ,
@@ -133,7 +139,8 @@ func TestResolveDotfiles(t *testing.T) {
133139 },
134140 },
135141 {
136- Path : "vimrc" ,
142+ Path : "vimrc" ,
143+ Added : true ,
137144 Sources : []* SourceFile {
138145 {
139146 Group : "machines/desktop" ,
@@ -152,9 +159,11 @@ func TestResolveDotfiles(t *testing.T) {
152159 {
153160 Path : "bashrc" ,
154161 Removed : true ,
162+ Added : false ,
155163 },
156164 {
157- Path : "vimrc" ,
165+ Path : "vimrc" ,
166+ Added : false ,
158167 Sources : []* SourceFile {
159168 {
160169 Group : "base" ,
@@ -187,7 +196,8 @@ func TestResolveDotfiles(t *testing.T) {
187196 Groups : []string {"base" , "machines/desktop" , "machines/server" },
188197 Expected : Dotfiles {
189198 {
190- Path : "bash/file1" ,
199+ Path : "bash/file1" ,
200+ Added : true ,
191201 Sources : []* SourceFile {
192202 {
193203 Group : "base" ,
@@ -205,7 +215,8 @@ func TestResolveDotfiles(t *testing.T) {
205215 },
206216 },
207217 {
208- Path : "bash/file2" ,
218+ Path : "bash/file2" ,
219+ Added : true ,
209220 Sources : []* SourceFile {
210221 {
211222 Group : "base" ,
@@ -219,7 +230,8 @@ func TestResolveDotfiles(t *testing.T) {
219230 },
220231 },
221232 {
222- Path : "bash/file3" ,
233+ Path : "bash/file3" ,
234+ Added : true ,
223235 Sources : []* SourceFile {
224236 {
225237 Group : "base" ,
@@ -229,7 +241,8 @@ func TestResolveDotfiles(t *testing.T) {
229241 },
230242 },
231243 {
232- Path : "bash/file4" ,
244+ Path : "bash/file4" ,
245+ Added : true ,
233246 Sources : []* SourceFile {
234247 {
235248 Group : "base" ,
0 commit comments