Last active
May 11, 2023 15:02
-
-
Save programarivm/1c05400a6bafe70ffb97eb0f2e944b3c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\DataFixtures; | |
use App\Entity\User; | |
use Doctrine\Bundle\FixturesBundle\Fixture; | |
use Doctrine\Common\Persistence\ObjectManager; | |
class UserFixtures extends Fixture | |
{ | |
public function load(ObjectManager $manager) | |
{ | |
$user = new User(); | |
$user->setUsername('bob'); | |
$manager->persist($user); | |
$manager->flush(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment