1 // =============================================================================
2 // Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
3 // Copyright (C) 2009 - DIGITEO - Pierre MARECHAL <pierre.marechal@scilab.org>
5 // This file is distributed under the same license as the Scilab package.
6 // =============================================================================
7 // <-- CLI SHELL MODE -->
8 // <-- ENGLISH IMPOSED -->
9 load("SCI/modules/atoms/macros/atoms_internals/lib");
10 // We need a clean version
11 // =============================================================================
12 if ~isempty( atomsGetInstalled() ) then bugmes();quit;end
13 // If previous test did not end properly, restore, else backup config file
14 atomsRestoreConfig(%T);
16 //force official ATOMS repository
17 atomsRepositorySetOfl(mgetl(SCI+"/modules/atoms/tests/unit_tests/repositories.orig"));
18 Scanning repository http://atoms.scilab.org/6.0 ... Done
19 // Set some parameters for the test
20 // =============================================================================
21 atomsSetConfig("autoloadAddAfterInstall","False");
22 atomsSetConfig("Verbose" ,"False");
23 // 1st test-case : Just install the toolbox 5
24 // =============================================================================
25 atomsInstall("toolbox_5V6");
26 // Check if the module is really installed
27 if ~ and( atomsIsInstalled( ["toolbox_5V6" "1.2" ; ..
28 "toolbox_4V6" "1.1" ; ..
29 "toolbox_2V6" "1.0" ; ..
30 "toolbox_1V6" "2.0"])) then bugmes();quit;end
31 atomsLoad("toolbox_5V6");
40 if ~ atomsIsLoaded("toolbox_5V6") then bugmes();quit;end
41 if ~ atomsIsLoaded(["toolbox_5V6" "1.2"]) then bugmes();quit;end
42 if ~ and(atomsIsLoaded(["toolbox_5V6"; ..
45 "toolbox_4V6"])) then bugmes();quit;end
46 if ~ and(atomsIsLoaded(["toolbox_5V6" "1.2"; ..
47 "toolbox_2V6" "1.0"; ..
48 "toolbox_1V6" "2.0"; ..
49 "toolbox_4V6" "1.1"])) then bugmes();quit;end
50 if or( t5_version() <> ["Toolbox 5 -> version = 1.2"; ..
51 "Toolbox 4 -> version = 1.1"; ..
52 "Toolbox 2 -> version = 1.0"; ..
53 "Toolbox 1 -> version = 2.0" ] ) then bugmes();quit;end
54 atomsRemove("toolbox_5V6");
55 the package toolbox_5V6 (1.2-1) is currently loaded, It will be removed at next Scilab start
56 the package toolbox_4V6 (1.1-1) is currently loaded, It will be removed at next Scilab start
57 the package toolbox_2V6 (1.0-1) is currently loaded, It will be removed at next Scilab start
58 the package toolbox_1V6 (2.0-1) is currently loaded, It will be removed at next Scilab start
59 // Restore original values
60 // =============================================================================
61 atomsRestoreConfig(%T);