1// =============================================================================
2// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
3// Copyright (C) 2009 - DIGITEO - Pierre MARECHAL <pierre.marechal@scilab.org>
4//
5//  This file is distributed under the same license as the Scilab package.
6// =============================================================================
7
8// <-- ENGLISH IMPOSED -->
9// <-- CLI SHELL MODE -->
10
11load("SCI/modules/atoms/macros/atoms_internals/lib");
12
13// If previous test did not end properly, restore, else backup config file
14atomsRestoreConfig(%T);
15atomsSaveConfig();
16
17// Do not use the autoload system
18atomsSetConfig("autoloadAddAfterInstall","False");
19atomsSetConfig("Verbose" ,"False");
20
21// Load the 1st scenario : See scene10.test.atoms.scilab.org.txt
22atomsRepositorySetOfl("http://scene10.6.0.test.atoms.scilab.org");
23
24// Install the toolbox 5
25// =============================================================================
26
27atomsInstall("toolbox_5V6");
28
29// Check if the module is really installed
30if ~atomsIsInstalled("toolbox_5V6")           then pause, end
31if ~atomsIsInstalled(["toolbox_5V6" "1.0"])   then pause, end
32if ~atomsIsInstalled(["toolbox_5V6" "1.0-1"]) then pause, end
33if ~atomsIsInstalled("toolbox_4V6")           then pause, end
34if ~atomsIsInstalled("toolbox_2V6")           then pause, end
35if ~atomsIsInstalled("toolbox_1V6")           then pause, end
36
37// Remove the module
38atomsRemove("toolbox_5V6");
39
40// Install the toolbox 5 (version is mentioned)
41// =============================================================================
42
43atomsInstall(["toolbox_5V6" "1.0"]);
44
45// Check if the module is really installed
46if ~atomsIsInstalled("toolbox_5V6")           then pause, end
47if ~atomsIsInstalled(["toolbox_5V6" "1.0"])   then pause, end
48if ~atomsIsInstalled(["toolbox_5V6" "1.0-1"]) then pause, end
49if ~atomsIsInstalled("toolbox_4V6")           then pause, end
50if ~atomsIsInstalled("toolbox_2V6")           then pause, end
51if ~atomsIsInstalled("toolbox_1V6")           then pause, end
52
53// Remove the module
54atomsRemove("toolbox_5V6");
55
56// Install the toolbox 5 (version + packaging version are mentioned)
57// =============================================================================
58
59atomsInstall(["toolbox_5V6" "1.0-1"]);
60
61// Check if the module is really installed
62if ~atomsIsInstalled("toolbox_5V6")           then pause, end
63if ~atomsIsInstalled(["toolbox_5V6" "1.0"])   then pause, end
64if ~atomsIsInstalled(["toolbox_5V6" "1.0-1"]) then pause, end
65if ~atomsIsInstalled("toolbox_4V6")           then pause, end
66if ~atomsIsInstalled("toolbox_2V6")           then pause, end
67if ~atomsIsInstalled("toolbox_1V6")           then pause, end
68
69// Remove the module
70atomsRemove("toolbox_5V6");
71
72// Install the toolbox 5 (user section)
73// =============================================================================
74
75atomsInstall("toolbox_5V6","user");
76
77if ~atomsIsInstalled("toolbox_5V6","user") then pause, end
78if ~atomsIsInstalled("toolbox_4V6","user") then pause, end
79if ~atomsIsInstalled("toolbox_2V6","user") then pause, end
80if ~atomsIsInstalled("toolbox_1V6","user") then pause, end
81
82if atomsIsInstalled("toolbox_5V6","allusers") then pause, end
83if atomsIsInstalled("toolbox_4V6","allusers") then pause, end
84if atomsIsInstalled("toolbox_2V6","allusers") then pause, end
85if atomsIsInstalled("toolbox_1V6","allusers") then pause, end
86
87atomsRemove("toolbox_5V6","user");
88
89if atomsIsInstalled("toolbox_5V6","user") then pause, end
90if atomsIsInstalled("toolbox_4V6","user") then pause, end
91if atomsIsInstalled("toolbox_2V6","user") then pause, end
92if atomsIsInstalled("toolbox_1V6","user") then pause, end
93
94// Install the toolbox 5 (allusers section)
95// =============================================================================
96
97atomsInstall("toolbox_5V6","allusers");
98
99if ~atomsIsInstalled("toolbox_5V6","allusers") then pause, end
100if ~atomsIsInstalled("toolbox_4V6","allusers") then pause, end
101if ~atomsIsInstalled("toolbox_2V6","allusers") then pause, end
102if ~atomsIsInstalled("toolbox_1V6","allusers") then pause, end
103
104if atomsIsInstalled("toolbox_5V6","user") then pause, end
105if atomsIsInstalled("toolbox_4V6","user") then pause, end
106if atomsIsInstalled("toolbox_2V6","user") then pause, end
107if atomsIsInstalled("toolbox_1V6","user") then pause, end
108
109atomsRemove("toolbox_5V6","allusers");
110
111if atomsIsInstalled("toolbox_5V6","allusers") then pause, end
112if atomsIsInstalled("toolbox_4V6","allusers") then pause, end
113if atomsIsInstalled("toolbox_2V6","allusers") then pause, end
114if atomsIsInstalled("toolbox_1V6","allusers") then pause, end
115
116// Install the toolbox 5 (Both section)
117// =============================================================================
118
119atomsInstall("toolbox_5V6","allusers");
120atomsInstall("toolbox_5V6","user");
121
122if ~atomsIsInstalled("toolbox_5V6","allusers") then pause, end
123if ~atomsIsInstalled("toolbox_4V6","allusers") then pause, end
124if ~atomsIsInstalled("toolbox_2V6","allusers") then pause, end
125if ~atomsIsInstalled("toolbox_1V6","allusers") then pause, end
126
127if ~atomsIsInstalled("toolbox_5V6","user") then pause, end
128if ~atomsIsInstalled("toolbox_4V6","user") then pause, end
129if ~atomsIsInstalled("toolbox_2V6","user") then pause, end
130if ~atomsIsInstalled("toolbox_1V6","user") then pause, end
131
132atomsRemove("toolbox_5V6","allusers");
133if atomsIsInstalled("toolbox_5V6","allusers") then pause, end
134if atomsIsInstalled("toolbox_4V6","allusers") then pause, end
135if atomsIsInstalled("toolbox_2V6","allusers") then pause, end
136if atomsIsInstalled("toolbox_1V6","allusers") then pause, end
137
138if ~atomsIsInstalled("toolbox_5V6","user") then pause, end
139if ~atomsIsInstalled("toolbox_4V6","user") then pause, end
140if ~atomsIsInstalled("toolbox_2V6","user") then pause, end
141if ~atomsIsInstalled("toolbox_1V6","user") then pause, end
142
143atomsInstall("toolbox_5V6","allusers");
144atomsRemove("toolbox_5V6","user");
145
146if atomsIsInstalled("toolbox_5V6","user") then pause, end
147if atomsIsInstalled("toolbox_4V6","user") then pause, end
148if atomsIsInstalled("toolbox_2V6","user") then pause, end
149if atomsIsInstalled("toolbox_1V6","user") then pause, end
150
151if ~atomsIsInstalled("toolbox_5V6","allusers") then pause, end
152if ~atomsIsInstalled("toolbox_4V6","allusers") then pause, end
153if ~atomsIsInstalled("toolbox_2V6","allusers") then pause, end
154if ~atomsIsInstalled("toolbox_1V6","allusers") then pause, end
155
156atomsRemove("toolbox_5V6","allusers");
157
158// Install the toolbox 7 (Local package)
159// =============================================================================
160
161atomsInstall(SCI+"/modules/atoms/tests/unit_tests/toolbox_7V6_1.0-1.bin.zip","allusers");
162atomsInstall(SCI+"/modules/atoms/tests/unit_tests/toolbox_7V6_1.0-1.bin.zip","user");
163
164if ~atomsIsInstalled("toolbox_7V6","allusers") then pause, end
165if ~atomsIsInstalled("toolbox_7V6","user")     then pause, end
166
167atomsRemove("toolbox_7V6","allusers");
168
169if atomsIsInstalled("toolbox_7V6","allusers")  then pause, end
170if ~atomsIsInstalled("toolbox_7V6","user")     then pause, end
171
172atomsInstall(SCI+"/modules/atoms/tests/unit_tests/toolbox_7V6_1.0-1.bin.zip","allusers");
173atomsRemove("toolbox_7V6","user");
174
175if atomsIsInstalled("toolbox_7V6","user")      then pause, end
176if ~atomsIsInstalled("toolbox_7V6","allusers") then pause, end
177
178atomsRemove("toolbox_7V6","allusers");
179
180// Restore original values
181// =============================================================================
182atomsRestoreConfig(%T);
183
184atomsRepositorySetOfl(mgetl(SCI+"/modules/atoms/tests/unit_tests/repositories.orig"));
185