WordPress/gutenberg

Create Block: Add automated tests to scaffold

開放

#21,360 建立於 2020年4月2日

 (3 則留言) (4 個反應) (0 位負責人)JavaScript (3,893 個分叉)batch import
Good First IssueNeeds Dev[Status] In Progress[Tool] Create Block[Type] Enhancement

倉庫指標

星標
 (9,607 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

Is your feature request related to a problem? Please describe. In order to encourage users to write automated tests, the infrastructure for them should be included in the scaffold from create-block

Describe the solution you'd like Add an option for the esnext template that sets up automated tests that defaults to Y.

Describe alternatives you've considered The main alternative is documentation on how to add automated tests. While I think that's a good first step, scaffolding will ultimetely save time. Create-block is installed 70 times a week right now, if we save 5 minutes for each of those people, almost 6 hours a week will be saved. Across an entire year, that is over 12 days of time.

I also considered making it mandatory, but allowing it to be opted out makes sense to me since there is the possibility that someone may have no interest in automated tests or intends to structure them in a different way.

貢獻者指南