Fixed TAC_TC
[platform/core/dotnet/launcher.git] / tests / TCs / 4_TAC / README.md
1 # Test Case for dotnet-launcher - TAC
2
3 This script(TAC.py) is a test that verifies the behavior of **prefer_nuget_cache** metadata.
4 Verifies that the **assembly(.dll)** can be shared.
5 ```
6 <metadata key="http://tizen.org/metadata/prefer_nuget_cache" value="true" />
7 <metadata key="http://tizen.org/metadata/prefer_nuget_cache" value="false" />
8 ```
9
10 ### Usage
11
12 * Build tpk
13
14   Must be run(./BuildTPK.py) at least once.
15 ```
16 launcher/tests/Apps$ ./BuildTPK.py
17 ```
18
19 * Run **TAC** test
20 ```
21 launcher/tests/TCs$ ./4_TAC/TAC.py
22 launcher/tests/TCs/4_TAC$ ./TAC.py
23 ```
24
25 * Run individual test
26 ```
27 launcher/tests/TCs/4_TAC$ ./TAC.py TC_01
28 ```
29
30 ### Description
31 * TC_01
32 ```
33   PASS : The Launcher_TC_TAC_01 application must have TAC applied.
34 ```
35   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
36   2. The `.tac_symlink` folder and `symbolic link` files exist.
37   3. The number of `.dll` in the `.tac_symlink` folder and `.dll` in the `TAC` must match.
38   4. The original file of the `symbolic link` must exist in the `TAC`.
39   5. The nuget in the `TAC` should be loaded when running the application.
40 * TC_02
41 ```
42   PASS : The Launcher_TC_TAC_02 application must have TAC applied.
43 ```
44   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
45   2. Install the application with the `same package ID`.
46   3. The `.tac_symlink` folder and `symbolic link` files exist.
47   4. The number of `.dll` in the `.tac_symlink` folder and `.dll` in the `TAC` must match.
48   5. The original file of the `symbolic link` must exist in the `TAC`.
49   6. The nuget in the `TAC` should be loaded when running the application.
50 * TC_03
51 ```
52   PASS : The Launcher_TC_TAC_03 application is normally TAC applied when updating.
53 ```
54   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
55   2. Update the application with the `same package ID`.
56   3. The `.tac_symlink` folder and `symbolic link` files exist.
57   4. The number of `.dll` in the `.tac_symlink` folder and `.dll` in the `TAC` must match.
58   5. The original file of the `symbolic link` must exist in the `TAC`.
59   6. Changes to the nuget should be applied normally.
60   7. The nuget in the `TAC` should be loaded when running the application.
61 * TC_04
62 ```
63   PASS : The Launcher_TC_TAC_04 application should not apply TAC when updating.
64 ```
65   1. There is no `prefer_nuget_cache` metadata in the manifest.
66   2. Update the application with the `same package ID`.
67   3. The `.tac_symlink` folder should not exist.
68   4. The nugets prior to updating the application should not exist in the `TAC`.
69   5. The nuget in the `application` should be loaded when running the application.
70 * TC_05
71 ```
72   PASS : The Launcher_TC_TAC_05, Launcher_TC_TAC_06 applications using the same nuget are normally TAC applied.
73 ```
74   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
75   2. Install two different applications using the `same nuget`.
76   3. Both applications have a `.tac_symlink` folder and a `symbolic link` file.
77   4. The number of `.dll` in the `.tac_symlink` folder and `.dll` in the `TAC` must match.
78   5. The original file of the `symbolic link` must exist in the `TAC`.
79   6. Uninstall one application.
80   7. All previous nugets must exist.
81   8. The nuget in the `TAC` should be loaded when running the application.
82 * TC_06
83 ```
84   PASS : The Launcher_TC_TAC_07 application is normally TAC applied when uninstall.
85 ```
86   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
87   2. Install the application.
88   3. The `.tac_symlink` folder and `symbolic link` files exist.
89   4. The number of `.dll` in the `.tac_symlink` folder and `.dll` in the `TAC` must match.
90   5. The original file of the `symbolic link` must exist in the `TAC`.
91   6. Uninstall the application.
92   7. The nuget should not exist in the `TAC`.
93 * TC_07
94 ```
95   PASS : The Launcher_TC_TAC_08 application should be applied to TAC, but The Launcher_TC_TAC_09 application should not be applied to TAC.
96 ```
97   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
98   2. Install two different applications.
99   3. The two applications use the `same version` of nuget, but the `SHA value` is different.
100   4. The first installed application has a `.tac_symlink` folder and `symbolic link` files.
101   5. The number of `.dll` in the `.tac_symlink` folder and `.dll` in the `TAC` must match.
102   6. The original file of the `symbolic link` must exist in the `TAC`.
103   7. The second installed application does not have a `.tac_symlink` folder.
104   8. The nuget in the `application` should be loaded when running the second application.
105 * TC_08
106 ```
107   PASS : The Launcher_TC_TAC_10 application should match the information of nuget with the value of TAC database.
108 ```
109   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
110   2. The `.tac_symlink` folder and `symbolic link` files exist.
111   3. The information in `nuget` must match the `TAC database` value.
112 * TC_09
113 ```
114   PASS : The Launcher_TC_TAC_11 application must match the version of the nuget in .deps.json and the version of the nuget in TAC DB.
115 ```
116   1. The `prefer_nuget_cache` metadata value is `true` in the manifest.
117   2. The nuget version of .deps.json and the nuget version of TAC database must match.
118 ----
119
120 ### Note
121
122 * Precondition
123   - Clone the **dotnet-launcher** repository.
124   - The prerequisites are **sdb** and **python3.6+**.
125   - The script must be run on the **host PC**.
126
127 * SDBs
128
129     sdb with a smart device selector.
130 ```
131 [1] 192.168.250.250 - 0
132 [2] 002c02f56c7d6c66 - TW3
133 Select a device [1-2]: 2
134 ```