mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-20 22:23:16 +00:00
depot_remove.run: improve <remove_all/> tests
This commits introduces changes to test number 4, so it must keep more than one PKG. Also, it introduces a 5th test to verify that the <remove_all/> functionality does delete everything in the depot. Issue genodelabs#4866
This commit is contained in:
parent
3f661a75e4
commit
6881a71a87
@ -288,15 +288,17 @@ if { [check_depot_state $context] } {
|
||||
|
||||
puts " TEST 3 --- Delete a PKG archive with deps to keep --- SUCCESS"
|
||||
|
||||
puts "\n--------------- TEST 4 --- Remove all, keep themed_decorator PKG"
|
||||
puts "\n--------------- TEST 4 --- Remove all, keep themed_decorator and chroot PKGS"
|
||||
|
||||
set context [mark_all_for_deletion [build_depot_context]]
|
||||
set context [mark_pkg_to_keep $context "themed_decorator"]
|
||||
set context [mark_pkg_to_keep $context "chroot"]
|
||||
|
||||
install_test_config {
|
||||
<config arch="} [depot_spec] {" report="yes">
|
||||
<remove-all>
|
||||
<keep user="} [depot_user] {" pkg="themed_decorator"/>
|
||||
<keep user="} [depot_user] {" pkg="chroot"/>
|
||||
</remove-all>
|
||||
<vfs> <dir name="depot"> <fs/> </dir> </vfs>
|
||||
</config>}
|
||||
@ -304,9 +306,27 @@ install_test_config {
|
||||
run_genode_until ".*</removed_archives>" 10
|
||||
|
||||
if { [check_depot_state $context] } {
|
||||
puts " TEST 4 --- Remove all, keep themed_decorator PKG --- ERROR"
|
||||
puts " TEST 4 --- Remove all, keep themed_decorator and chroot PKGS --- ERROR"
|
||||
exit 1
|
||||
}
|
||||
|
||||
puts " TEST 4 --- Remove all, keep themed_decorator PKG --- SUCCESS"
|
||||
puts " TEST 4 --- Remove all, keep themed_decorator and chroot PKGS --- SUCCESS"
|
||||
|
||||
puts "\n--------------- TEST 5 --- Remove all --- SUCCESS"
|
||||
|
||||
set context [mark_all_for_deletion [build_depot_context]]
|
||||
|
||||
install_test_config {
|
||||
<config arch="} [depot_spec] {" report="yes">
|
||||
<remove-all/>
|
||||
<vfs> <dir name="depot"> <fs/> </dir> </vfs>
|
||||
</config>}
|
||||
|
||||
run_genode_until ".*</removed_archives>" 10
|
||||
|
||||
if { [check_depot_state $context] } {
|
||||
puts " TEST 5 --- Remove all --- ERROR"
|
||||
exit 1
|
||||
}
|
||||
|
||||
puts " TEST 5 --- Remove all --- SUCCESS"
|
||||
|
Loading…
Reference in New Issue
Block a user