Skip to content

Commit

Permalink
make command for development process
Browse files Browse the repository at this point in the history
  • Loading branch information
MetaMan committed Dec 6, 2024
1 parent bdda973 commit ffe5488
Showing 1 changed file with 46 additions and 0 deletions.
46 changes: 46 additions & 0 deletions app/Console/Commands/PrepareTestCase.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?php

namespace App\Console\Commands;

use App\Traits\DumpFromGit\CreateCategoriesAndGroupsTrait;
use App\Traits\DumpFromGit\CreateFederationTrait;
use App\Traits\EdugainTrait;
use App\Traits\GitTrait;
use Illuminate\Console\Command;
use Illuminate\Contracts\Console\Isolatable;

class PrepareTestCase extends Command implements Isolatable
{
use CreateCategoriesAndGroupsTrait,CreateFederationTrait,
EdugainTrait,
GitTrait;

/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'app:prefed';

/**
* The console command description.
*
* @var string
*/
protected $description = 'Prepare test case for federation groups and categories';

/**
* Execute the console command.
*/
public function handle(): void
{
$this->call('migrate:refresh');
$this->call('db:seed');

$this->initializeGit();
$this->createFederations();
$this->createCategoriesAndGroups();
$this->makeEdu2Edugain();

}
}

0 comments on commit ffe5488

Please sign in to comment.