(t *testing.T)
| 131 | } |
| 132 | |
| 133 | func TestNewAccessController(t *testing.T) { |
| 134 | config := &AccessControlConfig{ |
| 135 | SessionTimeout: 30 * time.Minute, |
| 136 | MaxSessionsPerUser: 5, |
| 137 | EnableAudit: true, |
| 138 | } |
| 139 | |
| 140 | auditLog := &mockAuditLog{} |
| 141 | ac := NewAccessController(config, auditLog) |
| 142 | |
| 143 | if ac == nil { |
| 144 | t.Fatal("expected AccessController, got nil") |
| 145 | } |
| 146 | |
| 147 | if ac.config.SessionTimeout != 30*time.Minute { |
| 148 | t.Errorf("expected SessionTimeout 30m, got %v", ac.config.SessionTimeout) |
| 149 | } |
| 150 | } |
| 151 | |
| 152 | func TestAccessController_CreateUser(t *testing.T) { |
| 153 | ac := NewAccessController(&AccessControlConfig{}, &mockAuditLog{}) |
nothing calls this directly
no test coverage detected