Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
bajramemini committed Jan 8, 2025
1 parent c401265 commit 350ed06
Showing 1 changed file with 21 additions and 11 deletions.
Original file line number Diff line number Diff line change
@@ -1,28 +1,38 @@
<?php

use Aura\Base\Facades\Aura;
use Aura\Base\Resources\Option;
use Aura\Base\Resources\Permission;
use Aura\Base\Resources\Role;
use Aura\Base\Resources\User;
use Aura\Base\Resources\Option;
use Aura\Base\Resources\Permission;
use Aura\Base\Tests\Resources\Post;

beforeAll(function () {
putenv('AURA_TEAMS=false');
});

afterAll(function () {
putenv('AURA_TEAMS=true');
});
use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Support\Facades\Artisan;
use Illuminate\Support\Facades\Schema;

// Before each test, create a Superadmin and login
beforeEach(function () {
beforeEach(function () {

$this->markTestSkipped('Skipped for now');
// Set teams to false for this test
config(['aura.teams' => false]);

// Drop all tables and run our migration
Schema::dropAllTables();
$migration = require __DIR__.'/../../database/migrations/create_aura_tables.php.stub';
$migration->up();

$this->actingAs($this->user = createSuperAdminWithoutTeam());

Aura::fake();
Aura::setModel(new Post);
});

afterEach(function () {
// Restore original config value
config(['aura.teams' => true]);
});

test('Aura without teams - pages', function () {

$this->withoutExceptionHandling();
Expand Down

0 comments on commit 350ed06

Please sign in to comment.