官术网_书友最值得收藏!

Categorization by FEATURE

By inspecting the names of the standard test codeunits, we got an impression of what kind of tests this collateral is made. Microsoft, however, has a better structured categorization, which so far, due to low priority, hasn't been explicitly shared with the outside world. Now that automated testing is being picked up more and more, it's pressing on Microsoft to put this on higher priority. But for now, we can access it already inside most of the test codeunits. You need to look for the FEATURE tag. This tag is part of the Acceptance Test-Driven Development (ATDD) test case design pattern, which we will be discussing later in Chapter 4, Test Design. Using the [FEATURE] tag, Microsoft categorizes their test codeunits and, in some cases, individual test functions. Note that this tagging is far from complete as not all test codeunits have it, yet.

Have a look at the (partial) abstract of the following codeunits:

  • Codeunit 134000 - ERM Apply Sales/Receivables:
    • OnRun:
      • [FEATURE] [Sales]
    • [Test] PROCEDURE VerifyAmountApplToExtDocNoWhenSetValue:
      • [FEATURE] [Application] [Cash Receipt]
    • [Test] PROCEDURE PmtJnlApplToInvWithNoDimDiscountAndDefDimErr:
      • [FEATURE] [Dimension] [Payment Discount]
  • Codeunit 134012 - ERM Reminder Apply Unapply:
    • OnRun:
      • [FEATURE] [Reminder] [Sales]
    • [Test] PROCEDURE CustomerLedgerEntryFactboxReminderPage:
      • [FEATURE] [UI]

In later chapters, we will look in more detail at various standard test functions. You will see how to take them as examples for your own test writing (Chapter 4, Test Design, Chapter 5, From Customer Wish to Test Automation - The Basics, Chapter 6, From Customer Wish to Test Automation - Next Level, and Chapter 7, From Customer Wish to Test Automation - And Some More), and how to get them to run on your own solution (Chapter 9, Getting Business Central Standard Tests Working on Your Code).

At this very moment, the standard test suite objects are to be found in the following ID ranges:
134000 to 139999: w1 tests
144000 to 149999: local tests
主站蜘蛛池模板: 镇坪县| 宜兰市| 黔西| 得荣县| 昌江| 时尚| 区。| 荃湾区| 区。| 古蔺县| 昆明市| 民勤县| 琼结县| 囊谦县| 澄江县| 措美县| 卫辉市| 昔阳县| 万年县| 沽源县| 乌拉特中旗| 雅安市| 阜阳市| 太原市| 临西县| 金阳县| 永丰县| 策勒县| 云浮市| 河津市| 灵宝市| 呼伦贝尔市| 融水| 鹿泉市| 南投县| 治县。| 枣强县| 金溪县| 永平县| 兴安县| 呼玛县|