@@ -71,7 +71,7 @@ func TestResolveFQBN(t *testing.T) {
71
71
require .NotNil (t , platformRelease .Platform )
72
72
require .Equal (t , platformRelease .Platform .String (), "arduino:avr" )
73
73
require .NotNil (t , board )
74
- require .Equal (t , board .Name (), "Arduino/Genuino Uno" )
74
+ require .Equal (t , board .Name (), "Arduino Uno" )
75
75
require .NotNil (t , props )
76
76
require .Equal (t , platformRelease , buildPlatformRelease )
77
77
@@ -85,7 +85,7 @@ func TestResolveFQBN(t *testing.T) {
85
85
require .NotNil (t , platformRelease .Platform )
86
86
require .Equal (t , platformRelease .Platform .String (), "arduino:avr" )
87
87
require .NotNil (t , board )
88
- require .Equal (t , board .Name (), "Arduino/Genuino Mega or Mega 2560" )
88
+ require .Equal (t , board .Name (), "Arduino Mega or Mega 2560" )
89
89
require .NotNil (t , props )
90
90
require .Equal (t , platformRelease , buildPlatformRelease )
91
91
@@ -460,6 +460,7 @@ func TestLegacyPackageConversionToPluggableDiscovery(t *testing.T) {
460
460
platformProps := platformRelease .Properties
461
461
require .Equal (t , "builtin:serial-discovery" , platformProps .Get ("pluggable_discovery.required.0" ))
462
462
require .Equal (t , "builtin:mdns-discovery" , platformProps .Get ("pluggable_discovery.required.1" ))
463
+ require .Equal (t , "builtin:serial-monitor" , platformProps .Get ("pluggable_monitor.required.serial" ))
463
464
require .Equal (t , "{runtime.tools.esptool.path}" , platformProps .Get ("tools.esptool__pluggable_network.path" ))
464
465
require .Contains (t , platformProps .Get ("tools.esptool__pluggable_network.cmd" ), "esptool" )
465
466
require .Contains (t , platformProps .Get ("tools.esptool__pluggable_network.network_cmd" ), "{runtime.platform.path}/tools/espota" )
@@ -481,6 +482,7 @@ func TestLegacyPackageConversionToPluggableDiscovery(t *testing.T) {
481
482
platformProps := platformRelease .Properties
482
483
require .Equal (t , "builtin:serial-discovery" , platformProps .Get ("pluggable_discovery.required.0" ))
483
484
require .Equal (t , "builtin:mdns-discovery" , platformProps .Get ("pluggable_discovery.required.1" ))
485
+ require .Equal (t , "builtin:serial-monitor" , platformProps .Get ("pluggable_monitor.required.serial" ))
484
486
require .Equal (t , "" , platformProps .Get ("tools.esptool__pluggable_network.path" ))
485
487
require .Equal (t , "{runtime.tools.python3.path}/python3" , platformProps .Get ("tools.esptool__pluggable_network.cmd" ))
486
488
require .Equal (t , "{runtime.tools.python3.path}/python3" , platformProps .Get ("tools.esptool__pluggable_network.network_cmd" ))
@@ -491,4 +493,18 @@ func TestLegacyPackageConversionToPluggableDiscovery(t *testing.T) {
491
493
require .Equal (t , "true" , platformProps .Get ("tools.esptool__pluggable_network.upload.field.password.secret" ))
492
494
require .Equal (t , "\" {network_cmd}\" -I \" {runtime.platform.path}/tools/espota.py\" -i \" {upload.port.address}\" -p \" {upload.port.properties.port}\" \" --auth={upload.field.password}\" -f \" {build.path}/{build.project_name}.bin\" " , platformProps .Get ("tools.esptool__pluggable_network.upload.pattern" ))
493
495
}
496
+ {
497
+ fqbn , err := cores .ParseFQBN ("arduino:avr:uno" )
498
+ require .NoError (t , err )
499
+ require .NotNil (t , fqbn )
500
+ _ , platformRelease , board , _ , _ , err := pm .ResolveFQBN (fqbn )
501
+ require .NoError (t , err )
502
+ require .Equal (t , "avrdude__pluggable_network" , board .Properties .Get ("upload.tool.network" ))
503
+ require .Equal (t , "uno" , board .Properties .Get ("upload_port.4.board" ))
504
+ platformProps := platformRelease .Properties
505
+ require .Equal (t , "builtin:serial-discovery" , platformProps .Get ("pluggable_discovery.required.0" ))
506
+ require .Equal (t , "builtin:mdns-discovery" , platformProps .Get ("pluggable_discovery.required.1" ))
507
+ require .Equal (t , "builtin:serial-monitor" , platformProps .Get ("pluggable_monitor.required.serial" ))
508
+ require .Equal (t , `"{network_cmd}" -address {upload.port.address} -port {upload.port.properties.port} -sketch "{build.path}/{build.project_name}.hex" -upload {upload.port.properties.endpoint_upload} -sync {upload.port.properties.endpoint_sync} -reset {upload.port.properties.endpoint_reset} -sync_exp {upload.port.properties.sync_return}` , platformProps .Get ("tools.avrdude__pluggable_network.upload.pattern" ))
509
+ }
494
510
}
0 commit comments