mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-09 17:28:48 +01:00
Merge branch 'jellyfin:master' into feature/EFUserData
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Threading.Tasks;
|
||||
using Jellyfin.Server.Implementations.Migrations;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Xunit;
|
||||
|
||||
namespace Jellyfin.Server.Implementations.Tests.EfMigrations;
|
||||
|
||||
public class EfMigrationTests
|
||||
{
|
||||
[Fact]
|
||||
public void CheckForUnappliedMigrations()
|
||||
{
|
||||
var dbDesignContext = new DesignTimeJellyfinDbFactory();
|
||||
var context = dbDesignContext.CreateDbContext([]);
|
||||
Assert.False(context.Database.HasPendingModelChanges(), "There are unapplied changes to the EfCore model. Please create a Migration.");
|
||||
}
|
||||
}
|
||||
@@ -10,6 +10,9 @@ namespace Jellyfin.Server.Implementations.Tests.Users
|
||||
[InlineData("this_is_valid")]
|
||||
[InlineData("this is also valid")]
|
||||
[InlineData("0@_-' .")]
|
||||
[InlineData("Aa0@_-' .+")]
|
||||
[InlineData("thisisa+testemail@test.foo")]
|
||||
[InlineData("------@@@--+++----@@--abcdefghijklmn---------@----_-_-___-_ .9foo+")]
|
||||
public void ThrowIfInvalidUsername_WhenValidUsername_DoesNotThrowArgumentException(string username)
|
||||
{
|
||||
var ex = Record.Exception(() => UserManager.ThrowIfInvalidUsername(username));
|
||||
|
||||
Reference in New Issue
Block a user