2 Feature: Installing Tails to a USB drive, upgrading it, and using persistence
4 I may want to install Tails to a USB drive
5 and upgrade it to new Tails versions
8 # An issue with this feature is that scenarios depend on each other.
9 # For instance, "Tails boot from USB drive without persistent
10 # partition" depends on "Install Tails to a USB drive". This feels
11 # strange, but the alternative would be gigantic scenarios that
12 # test what to me feels like logically different features, e.g.
13 # the two named above would be concatenated.
15 Scenario: Installing Tails to a pristine USB drive
17 And the computer is set to boot from the Tails DVD
18 And the network is unplugged
19 And I start the computer
20 When the computer boots Tails
21 And I log in to a new session
23 And I have closed all annoying notifications
24 And I create a new 4 GiB USB drive named "current"
25 And I plug USB drive "current"
26 And I "Clone & Install" Tails to USB drive "current"
27 Then Tails is installed on USB drive "current"
28 But there is no persistence partition on USB drive "current"
29 And I unplug USB drive "current"
31 Scenario: Booting Tails from a USB drive without a persistent partition
33 And the computer is set to boot from USB drive "current"
34 And the network is unplugged
35 When I start the computer
36 And the computer boots Tails
37 And I log in to a new session
38 Then Tails seems to have booted normally
39 And Tails is running from USB drive "current"
40 And the boot device has safe access rights
41 And there is no persistence partition on USB drive "current"
43 Scenario: Creating a persistent partition
45 And the computer is set to boot from USB drive "current"
46 And the network is unplugged
47 When I start the computer
48 And the computer boots Tails
49 And Tails is running from USB drive "current"
50 And the boot device has safe access rights
51 And I log in to a new session
53 And I have closed all annoying notifications
54 And there is no persistence partition on USB drive "current"
55 And I create a persistent partition with password "asdf"
56 Then a Tails persistence partition with password "asdf" exists on USB drive "current"
57 And I completely shutdown Tails
59 Scenario: Booting Tails from a USB drive with a disabled persistent partition
61 And the computer is set to boot from USB drive "current"
62 And the network is unplugged
63 When I start the computer
64 And the computer boots Tails
65 And I log in to a new session
66 Then Tails seems to have booted normally
67 And Tails is running from USB drive "current"
68 And the boot device has safe access rights
69 And persistence is not enabled
70 But a Tails persistence partition with password "asdf" exists on USB drive "current"
72 Scenario: Writing files to a read/write-enabled persistent partition
74 And the computer is set to boot from USB drive "current"
75 And the network is unplugged
76 When I start the computer
77 And the computer boots Tails
78 And Tails is running from USB drive "current"
79 And the boot device has safe access rights
80 And I enable persistence with password "asdf"
81 And I log in to a new session
83 And I have closed all annoying notifications
84 And persistence has been enabled
85 And I write some files expected to persist
86 And I completely shutdown Tails
87 Then only the expected files should persist on USB drive "current"
89 Scenario: Writing files to a read-only-enabled persistent partition
91 And the computer is set to boot from USB drive "current"
92 And the network is unplugged
93 When I start the computer
94 And the computer boots Tails
95 And Tails is running from USB drive "current"
96 And the boot device has safe access rights
97 And I enable read-only persistence with password "asdf"
98 And I log in to a new session
100 And I have closed all annoying notifications
101 And persistence has been enabled
102 And I write some files not expected to persist
103 And I remove some files expected to persist
104 And I completely shutdown Tails
105 Then only the expected files should persist on USB drive "current"
107 Scenario: Deleting a Tails persistent partition
109 And the computer is set to boot from USB drive "current"
110 And the network is unplugged
111 And I start the computer
112 And the computer boots Tails
113 And I log in to a new session
114 And Tails is running from USB drive "current"
115 And the boot device has safe access rights
116 And Tails seems to have booted normally
117 And persistence is not enabled
118 But a Tails persistence partition with password "asdf" exists on USB drive "current"
119 And I have closed all annoying notifications
120 When I delete the persistent partition
121 Then there is no persistence partition on USB drive "current"
123 Scenario: Installing an old version of Tails to a pristine USB drive
125 And the computer is set to boot from the old Tails DVD
126 And the network is unplugged
127 And I start the computer
128 When the computer boots Tails
129 And I log in to a new session
130 And GNOME has started
131 And I have closed all annoying notifications
132 And I create a new 4 GiB USB drive named "old"
133 And I plug USB drive "old"
134 And I "Clone & Install" Tails to USB drive "old"
135 Then Tails is installed on USB drive "old"
136 But there is no persistence partition on USB drive "old"
137 And I unplug USB drive "old"
139 Scenario: Creating a persistent partition with the old Tails USB installation
141 And the computer is set to boot from USB drive "old"
142 And the network is unplugged
143 When I start the computer
144 And the computer boots Tails
145 And Tails is running from USB drive "old"
146 And I log in to a new session
147 And GNOME has started
148 And I have closed all annoying notifications
149 And I create a persistent partition with password "asdf"
150 Then a Tails persistence partition with password "asdf" exists on USB drive "old"
151 And I completely shutdown Tails
153 Scenario: Writing files to a read/write-enabled persistent partition with the old Tails USB installation
155 And the computer is set to boot from USB drive "old"
156 And the network is unplugged
157 When I start the computer
158 And the computer boots Tails
159 And Tails is running from USB drive "old"
160 And I enable persistence with password "asdf"
161 And I log in to a new session
162 And GNOME has started
163 And I have closed all annoying notifications
164 And persistence has been enabled
165 And I write some files expected to persist
166 And I completely shutdown Tails
167 Then only the expected files should persist on USB drive "old"
169 Scenario: Upgrading an old Tails USB installation from a Tails DVD
171 And I clone USB drive "old" to a new USB drive "to_upgrade"
172 And the computer is set to boot from the Tails DVD
173 And the network is unplugged
174 When I start the computer
175 And the computer boots Tails
176 And I log in to a new session
177 And GNOME has started
178 And I have closed all annoying notifications
179 And I plug USB drive "to_upgrade"
180 And I "Clone & Upgrade" Tails to USB drive "to_upgrade"
181 Then Tails is installed on USB drive "to_upgrade"
182 And I unplug USB drive "to_upgrade"
184 Scenario: Booting Tails from a USB drive upgraded from DVD with persistence enabled
186 And the computer is set to boot from USB drive "to_upgrade"
187 And the network is unplugged
188 When I start the computer
189 And the computer boots Tails
190 And I enable read-only persistence with password "asdf"
191 And I log in to a new session
192 Then Tails seems to have booted normally
193 And Tails is running from USB drive "to_upgrade"
194 And the boot device has safe access rights
195 And the expected persistent files are present in the filesystem
197 Scenario: Upgrading an old Tails USB installation from another Tails USB drive
199 And I clone USB drive "old" to a new USB drive "to_upgrade"
200 And the computer is set to boot from USB drive "current"
201 And the network is unplugged
202 When I start the computer
203 And the computer boots Tails
204 And Tails is running from USB drive "current"
205 And the boot device has safe access rights
206 And I log in to a new session
207 And GNOME has started
208 And I have closed all annoying notifications
209 And I plug USB drive "to_upgrade"
210 And I "Clone & Upgrade" Tails to USB drive "to_upgrade"
211 Then Tails is installed on USB drive "to_upgrade"
212 And I unplug USB drive "to_upgrade"
213 And I unplug USB drive "current"
215 Scenario: Booting Tails from a USB drive upgraded from USB with persistence enabled
217 And the computer is set to boot from USB drive "to_upgrade"
218 And the network is unplugged
219 When I start the computer
220 And the computer boots Tails
221 And I enable read-only persistence with password "asdf"
222 And I log in to a new session
223 Then Tails seems to have booted normally
224 And persistence has been enabled
225 And Tails is running from USB drive "to_upgrade"
226 And the boot device has safe access rights
227 And the expected persistent files are present in the filesystem
229 Scenario: Upgrading an old Tails USB installation from an ISO image
231 And I clone USB drive "old" to a new USB drive "to_upgrade"
232 And the computer is set to boot from the Tails DVD
233 And the network is unplugged
234 And I setup a filesystem share containing the Tails ISO
235 When I start the computer
236 And the computer boots Tails
237 And I log in to a new session
238 And GNOME has started
239 And I have closed all annoying notifications
240 And I plug USB drive "to_upgrade"
241 And I do a "Upgrade from ISO" on USB drive "to_upgrade"
242 Then Tails is installed on USB drive "to_upgrade"
243 And I unplug USB drive "to_upgrade"
245 Scenario: Booting Tails from a USB drive upgraded from ISO with persistence enabled
247 And the computer is set to boot from USB drive "to_upgrade"
248 And the network is unplugged
249 When I start the computer
250 And the computer boots Tails
251 And I enable read-only persistence with password "asdf"
252 And I log in to a new session
253 Then Tails seems to have booted normally
254 And persistence has been enabled
255 And Tails is running from USB drive "to_upgrade"
256 And the boot device has safe access rights
257 And the expected persistent files are present in the filesystem
259 Scenario: Installing Tails to a USB drive with an MBR partition table but no partitions
261 And I create a 2 GiB disk named "mbr"
262 And I create a msdos label on disk "mbr"
263 And the computer is set to boot from the Tails DVD
264 And the network is unplugged
265 And I start the computer
266 When the computer boots Tails
267 And I log in to a new session
268 And GNOME has started
269 And I have closed all annoying notifications
270 And I plug USB drive "mbr"
271 And I "Clone & Install" Tails to USB drive "mbr"
272 Then Tails is installed on USB drive "mbr"
273 But there is no persistence partition on USB drive "mbr"
274 And I unplug USB drive "mbr"
276 Scenario: Booting Tails from a USB drive that originally had an MBR partition table but no partitions, without a persistent partition
278 And the computer is set to boot from USB drive "mbr"
279 And the network is unplugged
280 When I start the computer
281 And the computer boots Tails
282 And I log in to a new session
283 Then Tails seems to have booted normally
284 And Tails is running from USB drive "mbr"
285 And the boot device has safe access rights
286 And there is no persistence partition on USB drive "mbr"
288 Scenario: Cat:ing a Tails isohybrid to a USB drive and booting it
290 And I create a 2 GiB disk named "isohybrid"
291 And I cat an ISO hybrid of the Tails image to disk "isohybrid"
292 And the computer is set to boot from USB drive "isohybrid"
293 And the network is unplugged
294 When I start the computer
295 And the computer boots Tails
296 And I log in to a new session
297 Then Tails seems to have booted normally
298 And Tails is running from USB drive "isohybrid"
300 Scenario: Try upgrading but end up installing Tails to a USB drive containing a Tails isohybrid installation
302 And the computer is set to boot from the Tails DVD
303 And the network is unplugged
304 And I start the computer
305 When the computer boots Tails
306 And I log in to a new session
307 And GNOME has started
308 And I have closed all annoying notifications
309 And I plug USB drive "isohybrid"
310 And I try a "Clone & Upgrade" Tails to USB drive "isohybrid"
311 But I am suggested to do a "Clone & Upgrade"
312 And I kill the process "liveusb-creator"
313 And I "Clone & Install" Tails to USB drive "isohybrid"
314 Then Tails is installed on USB drive "isohybrid"
315 But there is no persistence partition on USB drive "isohybrid"
316 And I unplug USB drive "isohybrid"
318 Scenario: Booting Tails from a USB drive that originally had a Tails isohybrid installation, without a persistent partition
320 And the computer is set to boot from USB drive "isohybrid"
321 And the network is unplugged
322 When I start the computer
323 And the computer boots Tails
324 And I log in to a new session
325 Then Tails seems to have booted normally
326 And Tails is running from USB drive "isohybrid"
327 And the boot device has safe access rights
328 And there is no persistence partition on USB drive "isohybrid"