+ /**
+ * Creates a block content type.
+ *
+ * @param string $id
+ * The block type id.
+ * @param string $label
+ * The block type label.
+ */
+ protected function createBlockContentType($id, $label) {
+ $bundle = BlockContentType::create([
+ 'id' => $id,
+ 'label' => $label,
+ 'revision' => 1,
+ ]);
+ $bundle->save();
+ block_content_add_body_field($bundle->id());
+ }
+