2016-10-17 15:44:49 -06:00
|
|
|
'use strict';
|
|
|
|
|
|
2019-06-12 23:53:43 -06:00
|
|
|
var tester = require('acme-dns-01-test');
|
2016-10-17 15:44:49 -06:00
|
|
|
|
2019-04-07 17:35:26 -06:00
|
|
|
var type = 'dns-01';
|
2019-06-12 23:53:43 -06:00
|
|
|
var challenger = require('./index.js').create({});
|
2018-05-12 19:17:26 -06:00
|
|
|
|
2019-04-07 17:35:26 -06:00
|
|
|
// The dry-run tests can pass on, literally, 'example.com'
|
|
|
|
|
// but the integration tests require that you have control over the domain
|
2019-06-12 23:53:43 -06:00
|
|
|
var zone = 'example.com';
|
2019-04-06 02:36:52 -06:00
|
|
|
|
2019-06-12 23:53:43 -06:00
|
|
|
tester
|
|
|
|
|
// will test example.com, foo.example.com, *.foo.example.com
|
|
|
|
|
.testZone(type, zone, challenger)
|
|
|
|
|
.then(function() {
|
|
|
|
|
console.info('PASS');
|
|
|
|
|
})
|
|
|
|
|
.catch(function(err) {
|
|
|
|
|
console.error('FAIL');
|
|
|
|
|
console.error(err);
|
|
|
|
|
process.exit(20);
|
|
|
|
|
});
|