File tree Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -235,10 +235,25 @@ mod test {
235
235
}
236
236
237
237
#[ test]
238
- fn test_fail_config_with_image_protocol_but_no_image ( ) {
238
+ fn test_config_with_image_protocol_but_no_image ( ) {
239
239
assert ! ( Config :: try_parse_from( & [ "onefetch" , "--image-protocol" , "sixel" ] ) . is_err( ) )
240
240
}
241
241
242
+ #[ test]
243
+ fn test_config_with_color_resolution_but_no_image ( ) {
244
+ assert ! ( Config :: try_parse_from( & [ "onefetch" , "--color-resolution" , "32" ] ) . is_err( ) )
245
+ }
246
+
247
+ #[ test]
248
+ fn test_config_with_ascii_colors_but_out_of_bounds ( ) {
249
+ assert ! ( Config :: try_parse_from( & [ "onefetch" , "--ascii-colors" , "17" ] ) . is_err( ) )
250
+ }
251
+
252
+ #[ test]
253
+ fn test_config_with_text_colors_but_out_of_bounds ( ) {
254
+ assert ! ( Config :: try_parse_from( & [ "onefetch" , "--text-colors" , "17" ] ) . is_err( ) )
255
+ }
256
+
242
257
fn get_default_config ( ) -> Config {
243
258
Config {
244
259
input : PathBuf :: from ( "." ) ,
You can’t perform that action at this time.
0 commit comments