mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
23 lines
533 B
TypeScript
23 lines
533 B
TypeScript
import ExternalMechanism = require('sasl-external');
|
|
import { Mechanism } from 'sasl-external';
|
|
import { Factory } from 'saslmechanisms';
|
|
|
|
new Factory().use(ExternalMechanism);
|
|
new Factory().use(Mechanism);
|
|
|
|
// $ExpectType "EXTERNAL"
|
|
ExternalMechanism.prototype.name;
|
|
// $ExpectType true
|
|
ExternalMechanism.prototype.clientFirst;
|
|
|
|
const m = new ExternalMechanism();
|
|
|
|
// $ExpectType "EXTERNAL"
|
|
m.name;
|
|
// $ExpectType true
|
|
m.clientFirst;
|
|
// $ExpectType string
|
|
m.response({ authzid: 'a' });
|
|
// $ExpectType void
|
|
m.challenge('challenge');
|