using System.Collections.Generic;
using System.Linq;
using AutoBogus;
using Util.Tests.Models;
namespace Util.Tests.Fakes;
///
/// 操作日志模拟数据服务
///
public static class OperationLogFakeService {
///
/// 获取操作日志
///
public static OperationLog GetOperationLog() {
return GetOperationLogs( 1 ).First();
}
///
/// 获取操作日志列表
///
/// 行数
public static List GetOperationLogs( int count ) {
return new AutoFaker()
.RuleFor( t => t.LogName, t => t.Random.String2( 1, 50 ) )
.Generate( count );
}
}