Test results

Library is put under several tests to ensure correct output format. Results are underneath with information about number of passed and failed tests.

Note

Majority of failed tests are linked to precision digits with floating-point based specifiers. This is considered as OK since failures are visible at higher number of precision digits, not affecting final results. Keep in mind that effective number of precision digits with float type is 7 and for double is 15.

With the exception to additional specifiers, supported only by LwPRINTF library, all tests are compared against stdio printf library included in Microsoft Visual Studio C/C++ compiler.

Test results of the library
   1------------------------
   2Number of tests run: 149
   3Number of tests passed: 141
   4Number of tests failed: 8
   5Coverage: 94.630875 %
   6------------------------
   7
   8Negative tests
   9
  10----
  11Format: "Precision: %3d, %20.*g"
  12Params: "i, i, 432432423.342321321"
  13Result VSprintf: "Precision:  19, 432432423.3423213363"
  14Length VSprintf: 36
  15Result LwPRINTF: "Precision:  19,  432432423.342321336"
  16Length LwPRINTF: 36
  17Test result: Fail
  18----
  19Format: "Precision: %3d, %20.*g"
  20Params: "i, i, 0.0001234567"
  21Result VSprintf: "Precision:  19, 0.0001234566999999999999"
  22Length VSprintf: 40
  23Result LwPRINTF: "Precision:  19,         0.0001234567"
  24Length LwPRINTF: 36
  25Test result: Fail
  26----
  27Format: "%.45f"
  28Params: "3.23321321"
  29Result VSprintf: "3.233213210000000170651901498786173760890960693"
  30Length VSprintf: 47
  31Result LwPRINTF: "3.233213210000000160000000000000000000000000000"
  32Length LwPRINTF: 47
  33Test result: Fail
  34----
  35Format: "%.45F"
  36Params: "3.23321321"
  37Result VSprintf: "3.233213210000000170651901498786173760890960693"
  38Length VSprintf: 47
  39Result LwPRINTF: "3.233213210000000160000000000000000000000000000"
  40Length LwPRINTF: 47
  41Test result: Fail
  42----
  43Format: "%22.33e"
  44Params: "123.456"
  45Result VSprintf: "1.234560000000000030695446184836328e+02"
  46Length VSprintf: 39
  47Result LwPRINTF: "1.234560000000000096000000000000000e+02"
  48Length LwPRINTF: 39
  49Test result: Fail
  50----
  51Format: "%22.33e"
  52Params: "-123.456"
  53Result VSprintf: "-1.234560000000000030695446184836328e+02"
  54Length VSprintf: 40
  55Result LwPRINTF: "-1.234560000000000096000000000000000e+02"
  56Length LwPRINTF: 40
  57Test result: Fail
  58----
  59Format: "%22.33e"
  60Params: "0.123456"
  61Result VSprintf: "1.234559999999999962971841682701779e-01"
  62Length VSprintf: 39
  63Result LwPRINTF: "1.234559999999999872000000000000000e-01"
  64Length LwPRINTF: 39
  65Test result: Fail
  66----
  67Format: "%22.33e"
  68Params: "-0.123456"
  69Result VSprintf: "-1.234559999999999962971841682701779e-01"
  70Length VSprintf: 40
  71Result LwPRINTF: "-1.234559999999999872000000000000000e-01"
  72Length LwPRINTF: 40
  73Test result: Fail
  74------------------------
  75
  76Positive tests
  77
  78----
  79Format: "Precision: %3d, %.*g"
  80Params: "17, 17, 0.0001234567"
  81Result VSprintf: "Precision:  17, 0.0001234567"
  82Length VSprintf: 28
  83Result LwPRINTF: "Precision:  17, 0.0001234567"
  84Length LwPRINTF: 28
  85Test result: Pass
  86----
  87Format: "Precision: %3d, %20.*g"
  88Params: "i, i, 432432423.342321321"
  89Result VSprintf: "Precision:   0,                4e+08"
  90Length VSprintf: 36
  91Result LwPRINTF: "Precision:   0,                4e+08"
  92Length LwPRINTF: 36
  93Test result: Pass
  94----
  95Format: "Precision: %3d, %20.*g"
  96Params: "i, i, 432432423.342321321"
  97Result VSprintf: "Precision:   1,                4e+08"
  98Length VSprintf: 36
  99Result LwPRINTF: "Precision:   1,                4e+08"
 100Length LwPRINTF: 36
 101Test result: Pass
 102----
 103Format: "Precision: %3d, %20.*g"
 104Params: "i, i, 432432423.342321321"
 105Result VSprintf: "Precision:   2,              4.3e+08"
 106Length VSprintf: 36
 107Result LwPRINTF: "Precision:   2,              4.3e+08"
 108Length LwPRINTF: 36
 109Test result: Pass
 110----
 111Format: "Precision: %3d, %20.*g"
 112Params: "i, i, 432432423.342321321"
 113Result VSprintf: "Precision:   3,             4.32e+08"
 114Length VSprintf: 36
 115Result LwPRINTF: "Precision:   3,             4.32e+08"
 116Length LwPRINTF: 36
 117Test result: Pass
 118----
 119Format: "Precision: %3d, %20.*g"
 120Params: "i, i, 432432423.342321321"
 121Result VSprintf: "Precision:   4,            4.324e+08"
 122Length VSprintf: 36
 123Result LwPRINTF: "Precision:   4,            4.324e+08"
 124Length LwPRINTF: 36
 125Test result: Pass
 126----
 127Format: "Precision: %3d, %20.*g"
 128Params: "i, i, 432432423.342321321"
 129Result VSprintf: "Precision:   5,           4.3243e+08"
 130Length VSprintf: 36
 131Result LwPRINTF: "Precision:   5,           4.3243e+08"
 132Length LwPRINTF: 36
 133Test result: Pass
 134----
 135Format: "Precision: %3d, %20.*g"
 136Params: "i, i, 432432423.342321321"
 137Result VSprintf: "Precision:   6,          4.32432e+08"
 138Length VSprintf: 36
 139Result LwPRINTF: "Precision:   6,          4.32432e+08"
 140Length LwPRINTF: 36
 141Test result: Pass
 142----
 143Format: "Precision: %3d, %20.*g"
 144Params: "i, i, 432432423.342321321"
 145Result VSprintf: "Precision:   7,         4.324324e+08"
 146Length VSprintf: 36
 147Result LwPRINTF: "Precision:   7,         4.324324e+08"
 148Length LwPRINTF: 36
 149Test result: Pass
 150----
 151Format: "Precision: %3d, %20.*g"
 152Params: "i, i, 432432423.342321321"
 153Result VSprintf: "Precision:   8,        4.3243242e+08"
 154Length VSprintf: 36
 155Result LwPRINTF: "Precision:   8,        4.3243242e+08"
 156Length LwPRINTF: 36
 157Test result: Pass
 158----
 159Format: "Precision: %3d, %20.*g"
 160Params: "i, i, 432432423.342321321"
 161Result VSprintf: "Precision:   9,            432432423"
 162Length VSprintf: 36
 163Result LwPRINTF: "Precision:   9,            432432423"
 164Length LwPRINTF: 36
 165Test result: Pass
 166----
 167Format: "Precision: %3d, %20.*g"
 168Params: "i, i, 432432423.342321321"
 169Result VSprintf: "Precision:  10,          432432423.3"
 170Length VSprintf: 36
 171Result LwPRINTF: "Precision:  10,          432432423.3"
 172Length LwPRINTF: 36
 173Test result: Pass
 174----
 175Format: "Precision: %3d, %20.*g"
 176Params: "i, i, 432432423.342321321"
 177Result VSprintf: "Precision:  11,         432432423.34"
 178Length VSprintf: 36
 179Result LwPRINTF: "Precision:  11,         432432423.34"
 180Length LwPRINTF: 36
 181Test result: Pass
 182----
 183Format: "Precision: %3d, %20.*g"
 184Params: "i, i, 432432423.342321321"
 185Result VSprintf: "Precision:  12,        432432423.342"
 186Length VSprintf: 36
 187Result LwPRINTF: "Precision:  12,        432432423.342"
 188Length LwPRINTF: 36
 189Test result: Pass
 190----
 191Format: "Precision: %3d, %20.*g"
 192Params: "i, i, 432432423.342321321"
 193Result VSprintf: "Precision:  13,       432432423.3423"
 194Length VSprintf: 36
 195Result LwPRINTF: "Precision:  13,       432432423.3423"
 196Length LwPRINTF: 36
 197Test result: Pass
 198----
 199Format: "Precision: %3d, %20.*g"
 200Params: "i, i, 432432423.342321321"
 201Result VSprintf: "Precision:  14,      432432423.34232"
 202Length VSprintf: 36
 203Result LwPRINTF: "Precision:  14,      432432423.34232"
 204Length LwPRINTF: 36
 205Test result: Pass
 206----
 207Format: "Precision: %3d, %20.*g"
 208Params: "i, i, 432432423.342321321"
 209Result VSprintf: "Precision:  15,     432432423.342321"
 210Length VSprintf: 36
 211Result LwPRINTF: "Precision:  15,     432432423.342321"
 212Length LwPRINTF: 36
 213Test result: Pass
 214----
 215Format: "Precision: %3d, %20.*g"
 216Params: "i, i, 432432423.342321321"
 217Result VSprintf: "Precision:  16,    432432423.3423213"
 218Length VSprintf: 36
 219Result LwPRINTF: "Precision:  16,    432432423.3423213"
 220Length LwPRINTF: 36
 221Test result: Pass
 222----
 223Format: "Precision: %3d, %20.*g"
 224Params: "i, i, 432432423.342321321"
 225Result VSprintf: "Precision:  17,   432432423.34232134"
 226Length VSprintf: 36
 227Result LwPRINTF: "Precision:  17,   432432423.34232134"
 228Length LwPRINTF: 36
 229Test result: Pass
 230----
 231Format: "Precision: %3d, %20.*g"
 232Params: "i, i, 432432423.342321321"
 233Result VSprintf: "Precision:  18,  432432423.342321336"
 234Length VSprintf: 36
 235Result LwPRINTF: "Precision:  18,  432432423.342321336"
 236Length LwPRINTF: 36
 237Test result: Pass
 238----
 239Format: "Precision: %3d, %20.*g"
 240Params: "i, i, 0.0001234567"
 241Result VSprintf: "Precision:   0,               0.0001"
 242Length VSprintf: 36
 243Result LwPRINTF: "Precision:   0,               0.0001"
 244Length LwPRINTF: 36
 245Test result: Pass
 246----
 247Format: "Precision: %3d, %20.*g"
 248Params: "i, i, 0.0001234567"
 249Result VSprintf: "Precision:   1,               0.0001"
 250Length VSprintf: 36
 251Result LwPRINTF: "Precision:   1,               0.0001"
 252Length LwPRINTF: 36
 253Test result: Pass
 254----
 255Format: "Precision: %3d, %20.*g"
 256Params: "i, i, 0.0001234567"
 257Result VSprintf: "Precision:   2,              0.00012"
 258Length VSprintf: 36
 259Result LwPRINTF: "Precision:   2,              0.00012"
 260Length LwPRINTF: 36
 261Test result: Pass
 262----
 263Format: "Precision: %3d, %20.*g"
 264Params: "i, i, 0.0001234567"
 265Result VSprintf: "Precision:   3,             0.000123"
 266Length VSprintf: 36
 267Result LwPRINTF: "Precision:   3,             0.000123"
 268Length LwPRINTF: 36
 269Test result: Pass
 270----
 271Format: "Precision: %3d, %20.*g"
 272Params: "i, i, 0.0001234567"
 273Result VSprintf: "Precision:   4,            0.0001235"
 274Length VSprintf: 36
 275Result LwPRINTF: "Precision:   4,            0.0001235"
 276Length LwPRINTF: 36
 277Test result: Pass
 278----
 279Format: "Precision: %3d, %20.*g"
 280Params: "i, i, 0.0001234567"
 281Result VSprintf: "Precision:   5,           0.00012346"
 282Length VSprintf: 36
 283Result LwPRINTF: "Precision:   5,           0.00012346"
 284Length LwPRINTF: 36
 285Test result: Pass
 286----
 287Format: "Precision: %3d, %20.*g"
 288Params: "i, i, 0.0001234567"
 289Result VSprintf: "Precision:   6,          0.000123457"
 290Length VSprintf: 36
 291Result LwPRINTF: "Precision:   6,          0.000123457"
 292Length LwPRINTF: 36
 293Test result: Pass
 294----
 295Format: "Precision: %3d, %20.*g"
 296Params: "i, i, 0.0001234567"
 297Result VSprintf: "Precision:   7,         0.0001234567"
 298Length VSprintf: 36
 299Result LwPRINTF: "Precision:   7,         0.0001234567"
 300Length LwPRINTF: 36
 301Test result: Pass
 302----
 303Format: "Precision: %3d, %20.*g"
 304Params: "i, i, 0.0001234567"
 305Result VSprintf: "Precision:   8,         0.0001234567"
 306Length VSprintf: 36
 307Result LwPRINTF: "Precision:   8,         0.0001234567"
 308Length LwPRINTF: 36
 309Test result: Pass
 310----
 311Format: "Precision: %3d, %20.*g"
 312Params: "i, i, 0.0001234567"
 313Result VSprintf: "Precision:   9,         0.0001234567"
 314Length VSprintf: 36
 315Result LwPRINTF: "Precision:   9,         0.0001234567"
 316Length LwPRINTF: 36
 317Test result: Pass
 318----
 319Format: "Precision: %3d, %20.*g"
 320Params: "i, i, 0.0001234567"
 321Result VSprintf: "Precision:  10,         0.0001234567"
 322Length VSprintf: 36
 323Result LwPRINTF: "Precision:  10,         0.0001234567"
 324Length LwPRINTF: 36
 325Test result: Pass
 326----
 327Format: "Precision: %3d, %20.*g"
 328Params: "i, i, 0.0001234567"
 329Result VSprintf: "Precision:  11,         0.0001234567"
 330Length VSprintf: 36
 331Result LwPRINTF: "Precision:  11,         0.0001234567"
 332Length LwPRINTF: 36
 333Test result: Pass
 334----
 335Format: "Precision: %3d, %20.*g"
 336Params: "i, i, 0.0001234567"
 337Result VSprintf: "Precision:  12,         0.0001234567"
 338Length VSprintf: 36
 339Result LwPRINTF: "Precision:  12,         0.0001234567"
 340Length LwPRINTF: 36
 341Test result: Pass
 342----
 343Format: "Precision: %3d, %20.*g"
 344Params: "i, i, 0.0001234567"
 345Result VSprintf: "Precision:  13,         0.0001234567"
 346Length VSprintf: 36
 347Result LwPRINTF: "Precision:  13,         0.0001234567"
 348Length LwPRINTF: 36
 349Test result: Pass
 350----
 351Format: "Precision: %3d, %20.*g"
 352Params: "i, i, 0.0001234567"
 353Result VSprintf: "Precision:  14,         0.0001234567"
 354Length VSprintf: 36
 355Result LwPRINTF: "Precision:  14,         0.0001234567"
 356Length LwPRINTF: 36
 357Test result: Pass
 358----
 359Format: "Precision: %3d, %20.*g"
 360Params: "i, i, 0.0001234567"
 361Result VSprintf: "Precision:  15,         0.0001234567"
 362Length VSprintf: 36
 363Result LwPRINTF: "Precision:  15,         0.0001234567"
 364Length LwPRINTF: 36
 365Test result: Pass
 366----
 367Format: "Precision: %3d, %20.*g"
 368Params: "i, i, 0.0001234567"
 369Result VSprintf: "Precision:  16,         0.0001234567"
 370Length VSprintf: 36
 371Result LwPRINTF: "Precision:  16,         0.0001234567"
 372Length LwPRINTF: 36
 373Test result: Pass
 374----
 375Format: "Precision: %3d, %20.*g"
 376Params: "i, i, 0.0001234567"
 377Result VSprintf: "Precision:  17,         0.0001234567"
 378Length VSprintf: 36
 379Result LwPRINTF: "Precision:  17,         0.0001234567"
 380Length LwPRINTF: 36
 381Test result: Pass
 382----
 383Format: "Precision: %3d, %20.*g"
 384Params: "i, i, 0.0001234567"
 385Result VSprintf: "Precision:  18,         0.0001234567"
 386Length VSprintf: 36
 387Result LwPRINTF: "Precision:  18,         0.0001234567"
 388Length LwPRINTF: 36
 389Test result: Pass
 390----
 391Format: "%.4f"
 392Params: "3.23321321"
 393Result VSprintf: "3.2332"
 394Length VSprintf: 6
 395Result LwPRINTF: "3.2332"
 396Length LwPRINTF: 6
 397Test result: Pass
 398----
 399Format: "%.4F"
 400Params: "3.23321321"
 401Result VSprintf: "3.2332"
 402Length VSprintf: 6
 403Result LwPRINTF: "3.2332"
 404Length LwPRINTF: 6
 405Test result: Pass
 406----
 407Format: "%g"
 408Params: "1.23342"
 409Result VSprintf: "1.23342"
 410Length VSprintf: 7
 411Result LwPRINTF: "1.23342"
 412Length LwPRINTF: 7
 413Test result: Pass
 414----
 415Format: "%g"
 416Params: "12334.2"
 417Result VSprintf: "12334.2"
 418Length VSprintf: 7
 419Result LwPRINTF: "12334.2"
 420Length LwPRINTF: 7
 421Test result: Pass
 422----
 423Format: "%.8g"
 424Params: "0.000000123342"
 425Result VSprintf: "1.23342e-07"
 426Length VSprintf: 11
 427Result LwPRINTF: "1.23342e-07"
 428Length LwPRINTF: 11
 429Test result: Pass
 430----
 431Format: "%.8G"
 432Params: "0.000000123342"
 433Result VSprintf: "1.23342E-07"
 434Length VSprintf: 11
 435Result LwPRINTF: "1.23342E-07"
 436Length LwPRINTF: 11
 437Test result: Pass
 438----
 439Format: "%.4f"
 440Params: "323243432432432.432"
 441Result VSprintf: "323243432432432.4375"
 442Length VSprintf: 20
 443Result LwPRINTF: "323243432432432.4375"
 444Length LwPRINTF: 20
 445Test result: Pass
 446----
 447Format: "%e"
 448Params: "-123.456"
 449Result VSprintf: "-1.234560e+02"
 450Length VSprintf: 13
 451Result LwPRINTF: "-1.234560e+02"
 452Length LwPRINTF: 13
 453Test result: Pass
 454----
 455Format: "%e"
 456Params: "0.000001"
 457Result VSprintf: "1.000000e-06"
 458Length VSprintf: 12
 459Result LwPRINTF: "1.000000e-06"
 460Length LwPRINTF: 12
 461Test result: Pass
 462----
 463Format: "%e"
 464Params: "0.123456"
 465Result VSprintf: "1.234560e-01"
 466Length VSprintf: 12
 467Result LwPRINTF: "1.234560e-01"
 468Length LwPRINTF: 12
 469Test result: Pass
 470----
 471Format: "%e"
 472Params: "-0.123456"
 473Result VSprintf: "-1.234560e-01"
 474Length VSprintf: 13
 475Result LwPRINTF: "-1.234560e-01"
 476Length LwPRINTF: 13
 477Test result: Pass
 478----
 479Format: "%.4e"
 480Params: "123.456"
 481Result VSprintf: "1.2346e+02"
 482Length VSprintf: 10
 483Result LwPRINTF: "1.2346e+02"
 484Length LwPRINTF: 10
 485Test result: Pass
 486----
 487Format: "%.4e"
 488Params: "-123.456"
 489Result VSprintf: "-1.2346e+02"
 490Length VSprintf: 11
 491Result LwPRINTF: "-1.2346e+02"
 492Length LwPRINTF: 11
 493Test result: Pass
 494----
 495Format: "%.4e"
 496Params: "0.123456"
 497Result VSprintf: "1.2346e-01"
 498Length VSprintf: 10
 499Result LwPRINTF: "1.2346e-01"
 500Length LwPRINTF: 10
 501Test result: Pass
 502----
 503Format: "%.4e"
 504Params: "-0.123456"
 505Result VSprintf: "-1.2346e-01"
 506Length VSprintf: 11
 507Result LwPRINTF: "-1.2346e-01"
 508Length LwPRINTF: 11
 509Test result: Pass
 510----
 511Format: "%.0e"
 512Params: "123.456"
 513Result VSprintf: "1e+02"
 514Length VSprintf: 5
 515Result LwPRINTF: "1e+02"
 516Length LwPRINTF: 5
 517Test result: Pass
 518----
 519Format: "%.0e"
 520Params: "-123.456"
 521Result VSprintf: "-1e+02"
 522Length VSprintf: 6
 523Result LwPRINTF: "-1e+02"
 524Length LwPRINTF: 6
 525Test result: Pass
 526----
 527Format: "%.0e"
 528Params: "0.123456"
 529Result VSprintf: "1e-01"
 530Length VSprintf: 5
 531Result LwPRINTF: "1e-01"
 532Length LwPRINTF: 5
 533Test result: Pass
 534----
 535Format: "%.0e"
 536Params: "-0.123456"
 537Result VSprintf: "-1e-01"
 538Length VSprintf: 6
 539Result LwPRINTF: "-1e-01"
 540Length LwPRINTF: 6
 541Test result: Pass
 542----
 543Format: "%22.4e"
 544Params: "123.456"
 545Result VSprintf: "            1.2346e+02"
 546Length VSprintf: 22
 547Result LwPRINTF: "            1.2346e+02"
 548Length LwPRINTF: 22
 549Test result: Pass
 550----
 551Format: "%22.4e"
 552Params: "-123.456"
 553Result VSprintf: "           -1.2346e+02"
 554Length VSprintf: 22
 555Result LwPRINTF: "           -1.2346e+02"
 556Length LwPRINTF: 22
 557Test result: Pass
 558----
 559Format: "%22.4e"
 560Params: "0.123456"
 561Result VSprintf: "            1.2346e-01"
 562Length VSprintf: 22
 563Result LwPRINTF: "            1.2346e-01"
 564Length LwPRINTF: 22
 565Test result: Pass
 566----
 567Format: "%22.4e"
 568Params: "-0.123456"
 569Result VSprintf: "           -1.2346e-01"
 570Length VSprintf: 22
 571Result LwPRINTF: "           -1.2346e-01"
 572Length LwPRINTF: 22
 573Test result: Pass
 574----
 575Format: "%022.4e"
 576Params: "123.456"
 577Result VSprintf: "0000000000001.2346e+02"
 578Length VSprintf: 22
 579Result LwPRINTF: "0000000000001.2346e+02"
 580Length LwPRINTF: 22
 581Test result: Pass
 582----
 583Format: "%022.4e"
 584Params: "-123.456"
 585Result VSprintf: "-000000000001.2346e+02"
 586Length VSprintf: 22
 587Result LwPRINTF: "-000000000001.2346e+02"
 588Length LwPRINTF: 22
 589Test result: Pass
 590----
 591Format: "%022.4e"
 592Params: "0.123456"
 593Result VSprintf: "0000000000001.2346e-01"
 594Length VSprintf: 22
 595Result LwPRINTF: "0000000000001.2346e-01"
 596Length LwPRINTF: 22
 597Test result: Pass
 598----
 599Format: "%e"
 600Params: "0.00000000123456"
 601Result VSprintf: "1.234560e-09"
 602Length VSprintf: 12
 603Result LwPRINTF: "1.234560e-09"
 604Length LwPRINTF: 12
 605Test result: Pass
 606----
 607Format: "%022.4e"
 608Params: "-0.123456"
 609Result VSprintf: "-000000000001.2346e-01"
 610Length VSprintf: 22
 611Result LwPRINTF: "-000000000001.2346e-01"
 612Length LwPRINTF: 22
 613Test result: Pass
 614----
 615Format: "%.4E"
 616Params: "-123.456"
 617Result VSprintf: "-1.2346E+02"
 618Length VSprintf: 11
 619Result LwPRINTF: "-1.2346E+02"
 620Length LwPRINTF: 11
 621Test result: Pass
 622----
 623Format: "% 3u"
 624Params: "(unsigned)28"
 625Result VSprintf: " 28"
 626Length VSprintf: 3
 627Result LwPRINTF: " 28"
 628Length LwPRINTF: 3
 629Test result: Pass
 630----
 631Format: "% 3u"
 632Params: "(unsigned)123456"
 633Result VSprintf: "123456"
 634Length VSprintf: 6
 635Result LwPRINTF: "123456"
 636Length LwPRINTF: 6
 637Test result: Pass
 638----
 639Format: "%03d"
 640Params: "28"
 641Result VSprintf: "028"
 642Length VSprintf: 3
 643Result LwPRINTF: "028"
 644Length LwPRINTF: 3
 645Test result: Pass
 646----
 647Format: "%+03d"
 648Params: "28"
 649Result VSprintf: "+28"
 650Length VSprintf: 3
 651Result LwPRINTF: "+28"
 652Length LwPRINTF: 3
 653Test result: Pass
 654----
 655Format: "%+3d"
 656Params: "28"
 657Result VSprintf: "+28"
 658Length VSprintf: 3
 659Result LwPRINTF: "+28"
 660Length LwPRINTF: 3
 661Test result: Pass
 662----
 663Format: "%03d"
 664Params: "-28"
 665Result VSprintf: "-28"
 666Length VSprintf: 3
 667Result LwPRINTF: "-28"
 668Length LwPRINTF: 3
 669Test result: Pass
 670----
 671Format: "%+03d"
 672Params: "-28"
 673Result VSprintf: "-28"
 674Length VSprintf: 3
 675Result LwPRINTF: "-28"
 676Length LwPRINTF: 3
 677Test result: Pass
 678----
 679Format: "%+3d"
 680Params: "-28"
 681Result VSprintf: "-28"
 682Length VSprintf: 3
 683Result LwPRINTF: "-28"
 684Length LwPRINTF: 3
 685Test result: Pass
 686----
 687Format: "%03u"
 688Params: "(unsigned)123456"
 689Result VSprintf: "123456"
 690Length VSprintf: 6
 691Result LwPRINTF: "123456"
 692Length LwPRINTF: 6
 693Test result: Pass
 694----
 695Format: "%-010uabc"
 696Params: "(unsigned)123456"
 697Result VSprintf: "123456    abc"
 698Length VSprintf: 13
 699Result LwPRINTF: "123456    abc"
 700Length LwPRINTF: 13
 701Test result: Pass
 702----
 703Format: "%010uabc"
 704Params: "(unsigned)123456"
 705Result VSprintf: "0000123456abc"
 706Length VSprintf: 13
 707Result LwPRINTF: "0000123456abc"
 708Length LwPRINTF: 13
 709Test result: Pass
 710----
 711Format: "%-10d"
 712Params: "-123"
 713Result VSprintf: "-123      "
 714Length VSprintf: 10
 715Result LwPRINTF: "-123      "
 716Length LwPRINTF: 10
 717Test result: Pass
 718----
 719Format: "%10d"
 720Params: "-123"
 721Result VSprintf: "      -123"
 722Length VSprintf: 10
 723Result LwPRINTF: "      -123"
 724Length LwPRINTF: 10
 725Test result: Pass
 726----
 727Format: "%-06d"
 728Params: "-1234567"
 729Result VSprintf: "-1234567"
 730Length VSprintf: 8
 731Result LwPRINTF: "-1234567"
 732Length LwPRINTF: 8
 733Test result: Pass
 734----
 735Format: "%06d"
 736Params: "-1234567"
 737Result VSprintf: "-1234567"
 738Length VSprintf: 8
 739Result LwPRINTF: "-1234567"
 740Length LwPRINTF: 8
 741Test result: Pass
 742----
 743Format: "%-10d"
 744Params: "-1234567"
 745Result VSprintf: "-1234567  "
 746Length VSprintf: 10
 747Result LwPRINTF: "-1234567  "
 748Length LwPRINTF: 10
 749Test result: Pass
 750----
 751Format: "%10d"
 752Params: "-1234567"
 753Result VSprintf: "  -1234567"
 754Length VSprintf: 10
 755Result LwPRINTF: "  -1234567"
 756Length LwPRINTF: 10
 757Test result: Pass
 758----
 759Format: "%-010d"
 760Params: "-1234567"
 761Result VSprintf: "-1234567  "
 762Length VSprintf: 10
 763Result LwPRINTF: "-1234567  "
 764Length LwPRINTF: 10
 765Test result: Pass
 766----
 767Format: "%010d"
 768Params: "-1234567"
 769Result VSprintf: "-001234567"
 770Length VSprintf: 10
 771Result LwPRINTF: "-001234567"
 772Length LwPRINTF: 10
 773Test result: Pass
 774----
 775Format: "%s"
 776Params: ""This is my string""
 777Result VSprintf: "This is my string"
 778Length VSprintf: 17
 779Result LwPRINTF: "This is my string"
 780Length LwPRINTF: 17
 781Test result: Pass
 782----
 783Format: "%10s"
 784Params: ""This is my string""
 785Result VSprintf: "This is my string"
 786Length VSprintf: 17
 787Result LwPRINTF: "This is my string"
 788Length LwPRINTF: 17
 789Test result: Pass
 790----
 791Format: "%0*d"
 792Params: "10, -123"
 793Result VSprintf: "-000000123"
 794Length VSprintf: 10
 795Result LwPRINTF: "-000000123"
 796Length LwPRINTF: 10
 797Test result: Pass
 798----
 799Format: "%zu"
 800Params: "(size_t)10"
 801Result VSprintf: "10"
 802Length VSprintf: 2
 803Result LwPRINTF: "10"
 804Length LwPRINTF: 2
 805Test result: Pass
 806----
 807Format: "%ju"
 808Params: "(uintmax_t)10"
 809Result VSprintf: "10"
 810Length VSprintf: 2
 811Result LwPRINTF: "10"
 812Length LwPRINTF: 2
 813Test result: Pass
 814----
 815Format: "% d"
 816Params: "1024"
 817Result VSprintf: " 1024"
 818Length VSprintf: 5
 819Result LwPRINTF: " 1024"
 820Length LwPRINTF: 5
 821Test result: Pass
 822----
 823Format: "% 4d"
 824Params: "1024"
 825Result VSprintf: " 1024"
 826Length VSprintf: 5
 827Result LwPRINTF: " 1024"
 828Length LwPRINTF: 5
 829Test result: Pass
 830----
 831Format: "% 3d"
 832Params: "1024"
 833Result VSprintf: " 1024"
 834Length VSprintf: 5
 835Result LwPRINTF: " 1024"
 836Length LwPRINTF: 5
 837Test result: Pass
 838----
 839Format: "% 3f"
 840Params: "32.687"
 841Result VSprintf: " 32.687000"
 842Length VSprintf: 10
 843Result LwPRINTF: " 32.687000"
 844Length LwPRINTF: 10
 845Test result: Pass
 846----
 847Format: "%*.*s"
 848Params: "8, 12, "This is my string""
 849Result VSprintf: "This is my s"
 850Length VSprintf: 12
 851Result LwPRINTF: "This is my s"
 852Length LwPRINTF: 12
 853Test result: Pass
 854----
 855Format: "%*.*s"
 856Params: "8, 12, "Stri""
 857Result VSprintf: "    Stri"
 858Length VSprintf: 8
 859Result LwPRINTF: "    Stri"
 860Length LwPRINTF: 8
 861Test result: Pass
 862----
 863Format: "%-6.10s"
 864Params: ""This is my string""
 865Result VSprintf: "This is my"
 866Length VSprintf: 10
 867Result LwPRINTF: "This is my"
 868Length LwPRINTF: 10
 869Test result: Pass
 870----
 871Format: "%6.10s"
 872Params: ""This is my string""
 873Result VSprintf: "This is my"
 874Length VSprintf: 10
 875Result LwPRINTF: "This is my"
 876Length LwPRINTF: 10
 877Test result: Pass
 878----
 879Format: "%-6.10s"
 880Params: ""This is my string""
 881Result VSprintf: "This is my"
 882Length VSprintf: 10
 883Result LwPRINTF: "This is my"
 884Length LwPRINTF: 10
 885Test result: Pass
 886----
 887Format: "%6.10s"
 888Params: ""Th""
 889Result VSprintf: "    Th"
 890Length VSprintf: 6
 891Result LwPRINTF: "    Th"
 892Length LwPRINTF: 6
 893Test result: Pass
 894----
 895Format: "%-6.10s"
 896Params: ""Th""
 897Result VSprintf: "Th    "
 898Length VSprintf: 6
 899Result LwPRINTF: "Th    "
 900Length LwPRINTF: 6
 901Test result: Pass
 902----
 903Format: "%*.*s"
 904Params: "-6, 10, "Th""
 905Result VSprintf: "Th    "
 906Length VSprintf: 6
 907Result LwPRINTF: "Th    "
 908Length LwPRINTF: 6
 909Test result: Pass
 910----
 911Format: "%*.*s"
 912Params: "6, 10, "Th""
 913Result VSprintf: "    Th"
 914Length VSprintf: 6
 915Result LwPRINTF: "    Th"
 916Length LwPRINTF: 6
 917Test result: Pass
 918----
 919Format: "%.4s"
 920Params: ""This is my string""
 921Result VSprintf: "This"
 922Length VSprintf: 4
 923Result LwPRINTF: "This"
 924Length LwPRINTF: 4
 925Test result: Pass
 926----
 927Format: "%.6s"
 928Params: ""1234""
 929Result VSprintf: "1234"
 930Length VSprintf: 4
 931Result LwPRINTF: "1234"
 932Length LwPRINTF: 4
 933Test result: Pass
 934----
 935Format: "%.4s"
 936Params: ""stri""
 937Result VSprintf: "stri"
 938Length VSprintf: 4
 939Result LwPRINTF: "stri"
 940Length LwPRINTF: 4
 941Test result: Pass
 942----
 943Format: "%.4s%.2s"
 944Params: ""123456", "abcdef""
 945Result VSprintf: "1234ab"
 946Length VSprintf: 6
 947Result LwPRINTF: "1234ab"
 948Length LwPRINTF: 6
 949Test result: Pass
 950----
 951Format: "%.4.2s"
 952Params: ""123456""
 953Result VSprintf: ".2s"
 954Length VSprintf: 3
 955Result LwPRINTF: ".2s"
 956Length LwPRINTF: 3
 957Test result: Pass
 958----
 959Format: "%.*s"
 960Params: "3, "123456""
 961Result VSprintf: "123"
 962Length VSprintf: 3
 963Result LwPRINTF: "123"
 964Length LwPRINTF: 3
 965Test result: Pass
 966----
 967Format: "%.3s"
 968Params: """"
 969Result VSprintf: ""
 970Length VSprintf: 0
 971Result LwPRINTF: ""
 972Length LwPRINTF: 0
 973Test result: Pass
 974----
 975Format: "%yunknown"
 976Params: """"
 977Result VSprintf: "yunknown"
 978Length VSprintf: 8
 979Result LwPRINTF: "yunknown"
 980Length LwPRINTF: 8
 981Test result: Pass
 982----
 983Format: "%#2X"
 984Params: "123"
 985Result VSprintf: "0X7B"
 986Length VSprintf: 4
 987Result LwPRINTF: "0X7B"
 988Length LwPRINTF: 4
 989Test result: Pass
 990----
 991Format: "%#2x"
 992Params: "123"
 993Result VSprintf: "0x7b"
 994Length VSprintf: 4
 995Result LwPRINTF: "0x7b"
 996Length LwPRINTF: 4
 997Test result: Pass
 998----
 999Format: "%#2o"
1000Params: "123"
1001Result VSprintf: "0173"
1002Length VSprintf: 4
1003Result LwPRINTF: "0173"
1004Length LwPRINTF: 4
1005Test result: Pass
1006----
1007Format: "%#2X"
1008Params: "1"
1009Result VSprintf: "0X1"
1010Length VSprintf: 3
1011Result LwPRINTF: "0X1"
1012Length LwPRINTF: 3
1013Test result: Pass
1014----
1015Format: "%#2x"
1016Params: "1"
1017Result VSprintf: "0x1"
1018Length VSprintf: 3
1019Result LwPRINTF: "0x1"
1020Length LwPRINTF: 3
1021Test result: Pass
1022----
1023Format: "%#2o"
1024Params: "1"
1025Result VSprintf: "01"
1026Length VSprintf: 2
1027Result LwPRINTF: "01"
1028Length LwPRINTF: 2
1029Test result: Pass
1030----
1031Format: "%#2X"
1032Params: "0"
1033Result VSprintf: " 0"
1034Length VSprintf: 2
1035Result LwPRINTF: " 0"
1036Length LwPRINTF: 2
1037Test result: Pass
1038----
1039Format: "%#2x"
1040Params: "0"
1041Result VSprintf: " 0"
1042Length VSprintf: 2
1043Result LwPRINTF: " 0"
1044Length LwPRINTF: 2
1045Test result: Pass
1046----
1047Format: "%#2o"
1048Params: "0"
1049Result VSprintf: " 0"
1050Length VSprintf: 2
1051Result LwPRINTF: " 0"
1052Length LwPRINTF: 2
1053Test result: Pass
1054----
1055Format: "%p"
1056Params: "&tests_passed"
1057Result VSprintf: "00BE0FD4"
1058Length VSprintf: 8
1059Result LwPRINTF: "00BE0FD4"
1060Length LwPRINTF: 8
1061Test result: Pass
1062----
1063Format: "0X%p"
1064Params: "&tests_passed"
1065Result VSprintf: "0X00BE0FD4"
1066Length VSprintf: 10
1067Result LwPRINTF: "0X00BE0FD4"
1068Length LwPRINTF: 10
1069Test result: Pass
1070----
1071Format: "0x%p"
1072Params: "&tests_passed"
1073Result VSprintf: "0x00BE0FD4"
1074Length VSprintf: 10
1075Result LwPRINTF: "0x00BE0FD4"
1076Length LwPRINTF: 10
1077Test result: Pass
1078----
1079Format: "%llb abc"
1080Params: "123"
1081Result expected: "1111011 abc"
1082Length expected: 11
1083Result LwPRINTF: "1111011 abc"
1084Length LwPRINTF: 11
1085Test result: Pass
1086----
1087Format: "%b"
1088Params: "4"
1089Result expected: "100"
1090Length expected: 3
1091Result LwPRINTF: "100"
1092Length LwPRINTF: 3
1093Test result: Pass
1094----
1095Format: "%#2B"
1096Params: "1"
1097Result expected: "0B1"
1098Length expected: 3
1099Result LwPRINTF: "0B1"
1100Length LwPRINTF: 3
1101Test result: Pass
1102----
1103Format: "%#2b"
1104Params: "1"
1105Result expected: "0b1"
1106Length expected: 3
1107Result LwPRINTF: "0b1"
1108Length LwPRINTF: 3
1109Test result: Pass
1110----
1111Format: "%#2B"
1112Params: "0"
1113Result expected: " 0"
1114Length expected: 2
1115Result LwPRINTF: " 0"
1116Length LwPRINTF: 2
1117Test result: Pass
1118----
1119Format: "%#2b"
1120Params: "0"
1121Result expected: " 0"
1122Length expected: 2
1123Result LwPRINTF: " 0"
1124Length LwPRINTF: 2
1125Test result: Pass
1126----
1127Format: "%#B"
1128Params: "0"
1129Result expected: "0"
1130Length expected: 1
1131Result LwPRINTF: "0"
1132Length LwPRINTF: 1
1133Test result: Pass
1134----
1135Format: "%#b"
1136Params: "0"
1137Result expected: "0"
1138Length expected: 1
1139Result LwPRINTF: "0"
1140Length LwPRINTF: 1
1141Test result: Pass
1142----
1143Format: "%#B"
1144Params: "6"
1145Result expected: "0B110"
1146Length expected: 5
1147Result LwPRINTF: "0B110"
1148Length LwPRINTF: 5
1149Test result: Pass
1150----
1151Format: "%#b"
1152Params: "6"
1153Result expected: "0b110"
1154Length expected: 5
1155Result LwPRINTF: "0b110"
1156Length LwPRINTF: 5
1157Test result: Pass
1158----
1159Format: "%5K"
1160Params: "my_arr"
1161Result expected: "0102B5C6D7"
1162Length expected: 10
1163Result LwPRINTF: "0102B5C6D7"
1164Length LwPRINTF: 10
1165Test result: Pass
1166----
1167Format: "%*K"
1168Params: "3, my_arr"
1169Result expected: "0102B5"
1170Length expected: 6
1171Result LwPRINTF: "0102B5"
1172Length LwPRINTF: 6
1173Test result: Pass
1174----
1175Format: "% *K"
1176Params: "3, my_arr"
1177Result expected: "01 02 B5"
1178Length expected: 8
1179Result LwPRINTF: "01 02 B5"
1180Length LwPRINTF: 8
1181Test result: Pass
1182----
1183Format: "%5k"
1184Params: "my_arr"
1185Result expected: "0102b5c6d7"
1186Length expected: 10
1187Result LwPRINTF: "0102b5c6d7"
1188Length LwPRINTF: 10
1189Test result: Pass
1190----
1191Format: "%*k"
1192Params: "3, my_arr"
1193Result expected: "0102b5"
1194Length expected: 6
1195Result LwPRINTF: "0102b5"
1196Length LwPRINTF: 6
1197Test result: Pass
1198----
1199Format: "% *k"
1200Params: "3, my_arr"
1201Result expected: "01 02 b5"
1202Length expected: 8
1203Result LwPRINTF: "01 02 b5"
1204Length LwPRINTF: 8
1205Test result: Pass