@@ -25,7 +25,7 @@ class AConan(ConanFile):
25
25
def _get_environ (self , ** kwargs ):
26
26
kwargs = super (ConanCenterTests , self )._get_environ (** kwargs )
27
27
kwargs .update ({'CONAN_HOOKS' : os .path .join (os .path .dirname (__file__ ), '..' , '..' , 'hooks' ,
28
- 'conan-center_reviewer ' )})
28
+ 'conan-center ' )})
29
29
return kwargs
30
30
31
31
def test_conanfile (self ):
@@ -40,7 +40,7 @@ def test_conanfile(self):
40
40
self .assertIn ("[LIBCXX] OK" , output )
41
41
self .assertIn ("[MATCHING CONFIGURATION] OK" , output )
42
42
self .assertIn ("[SHARED ARTIFACTS] OK" , output )
43
- self .assertIn ("ERROR: [PACKAGE LICENSE] No package licenses found" , output )
43
+ self .assertIn ("ERROR: [PACKAGE LICENSE] No ' licenses' folder found in package " , output )
44
44
self .assertIn ("[DEFAULT PACKAGE LAYOUT] OK" , output )
45
45
self .assertIn ("[SHARED ARTIFACTS] OK" , output )
46
46
print (output )
@@ -57,7 +57,7 @@ def test_conanfile_header_only(self):
57
57
self .assertIn ("[LIBCXX] OK" , output )
58
58
self .assertIn ("[MATCHING CONFIGURATION] OK" , output )
59
59
self .assertIn ("[SHARED ARTIFACTS] OK" , output )
60
- self .assertIn ("ERROR: [PACKAGE LICENSE] No package licenses found" , output )
60
+ self .assertIn ("ERROR: [PACKAGE LICENSE] No ' licenses' folder found in package " , output )
61
61
self .assertIn ("[DEFAULT PACKAGE LAYOUT] OK" , output )
62
62
self .assertIn ("[SHARED ARTIFACTS] OK" , output )
63
63
@@ -74,6 +74,26 @@ def test_conanfile_installer(self):
74
74
self .assertIn ("ERROR: [MATCHING CONFIGURATION] Built artifacts does not match the settings" ,
75
75
output )
76
76
self .assertIn ("[SHARED ARTIFACTS] OK" , output )
77
- self .assertIn ("ERROR: [PACKAGE LICENSE] No package licenses found" , output )
77
+ self .assertIn ("ERROR: [PACKAGE LICENSE] No ' licenses' folder found in package " , output )
78
78
self .assertIn ("[DEFAULT PACKAGE LAYOUT] OK" , output )
79
79
self .assertIn ("[SHARED ARTIFACTS] OK" , output )
80
+
81
+ def test_regular_folder_size (self ):
82
+ tools .save ('conanfile.py' , content = self .conanfile_installer )
83
+ output = self .conan (['export' , '.' , 'name/version@user/channel' ])
84
+ self .assertIn ("[RECIPE FOLDER SIZE] OK" , output )
85
+ self .assertNotIn ("ERROR: [RECIPE FOLDER SIZE]" , output )
86
+
87
+ def test_larger_folder_size (self ):
88
+ content = " " .join (["test_recipe_folder_larger_size" for it in range (1048576 )])
89
+ tools .save ('conanfile.py' , content = self .conanfile_installer )
90
+ tools .save ('big_file' , content = content )
91
+ output = self .conan (['export' , '.' , 'name/version@user/channel' ])
92
+ self .assertIn ("ERROR: [RECIPE FOLDER SIZE] The size of your recipe folder" , output )
93
+
94
+ def test_custom_folder_size (self ):
95
+ with tools .environment_append ({"CONAN_MAX_RECIPE_FOLDER_SIZE_KB" : "0" }):
96
+ content = " " .join (["test_recipe_folder_larger_size" for it in range (1048576 )])
97
+ tools .save ('conanfile.py' , content = self .conanfile_installer )
98
+ output = self .conan (['export' , '.' , 'name/version@user/channel' ])
99
+ self .assertIn ("ERROR: [RECIPE FOLDER SIZE] The size of your recipe folder" , output )
0 commit comments