diff --git a/.github/workflows/docker-alpine.yml b/.github/workflows/docker-alpine.yml index f274fc2c40..0a5c28ee53 100644 --- a/.github/workflows/docker-alpine.yml +++ b/.github/workflows/docker-alpine.yml @@ -76,7 +76,7 @@ jobs: with: context: . file: ./Dockerfile.alpine - platforms: linux/amd64 + platforms: linux/amd64,linux/arm64 # For pull requests, we run the Docker build (to ensure no PR changes break the build), # but we ONLY do an image push to DockerHub if it's NOT a PR push: ${{ github.event_name != 'pull_request' }} diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 323d90e41c..5aa2758e79 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -76,7 +76,7 @@ jobs: with: context: . file: ./Dockerfile - platforms: linux/amd64 + platforms: linux/amd64,linux/arm64 # For pull requests, we run the Docker build (to ensure no PR changes break the build), # but we ONLY do an image push to DockerHub if it's NOT a PR push: ${{ github.event_name != 'pull_request' }} diff --git a/app/Models/SnipeSCIMConfig.php b/app/Models/SnipeSCIMConfig.php index 77cbf01c1a..7ec25645e6 100644 --- a/app/Models/SnipeSCIMConfig.php +++ b/app/Models/SnipeSCIMConfig.php @@ -70,7 +70,11 @@ class SnipeSCIMConfig extends \ArieTimmerman\Laravel\SCIMServer\SCIMConfig // Map a SCIM attribute to an attribute of the object. 'mapping' => [ - 'id' => AttributeMapping::eloquent("id")->disableWrite(), + 'id' => (new AttributeMapping())->setRead( + function (&$object) { + return (string)$object->id; + } + )->disableWrite(), 'externalId' => AttributeMapping::eloquent('scim_externalid'), // FIXME - I have a PR that changes a lot of this. @@ -174,7 +178,6 @@ class SnipeSCIMConfig extends \ArieTimmerman\Laravel\SCIMServer\SCIMConfig '$ref' => null, 'display' => null, 'type' => null, - 'type' => null ]], 'entitlements' => null, diff --git a/tests/Feature/Users/UpdateUserTest.php b/tests/Feature/Users/UpdateUserTest.php index 7006cada62..9ddb323625 100644 --- a/tests/Feature/Users/UpdateUserTest.php +++ b/tests/Feature/Users/UpdateUserTest.php @@ -12,7 +12,7 @@ class UpdateUserTest extends TestCase public function testUsersCanBeActivated() { - $admin = User::factory()->admin()->create(); + $admin = User::factory()->superuser()->create(); $user = User::factory()->create(['activated' => false]); $this->actingAs($admin) @@ -27,7 +27,7 @@ class UpdateUserTest extends TestCase public function testUsersCanBeDeactivated() { - $admin = User::factory()->admin()->create(); + $admin = User::factory()->superuser()->create(); $user = User::factory()->create(['activated' => true]); $this->actingAs($admin) @@ -44,7 +44,7 @@ class UpdateUserTest extends TestCase public function testUsersUpdatingThemselvesDoNotDeactivateTheirAccount() { - $admin = User::factory()->admin()->create(['activated' => true]); + $admin = User::factory()->superuser()->create(['activated' => true]); $this->actingAs($admin) ->put(route('users.update', $admin), [