mirror of
https://github.com/renovatebot/renovate.git
synced 2025-01-12 15:06:27 +00:00
test(maven): Cover the case of void "last-modified" jar header (#12641)
This commit is contained in:
parent
7f4b119450
commit
811f81d3a2
5 changed files with 271 additions and 70 deletions
|
@ -26,8 +26,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://clojars.org/repo/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -71,8 +71,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -92,6 +92,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "clojars.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -148,6 +157,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://clojars.org/repo",
|
"registryUrl": "https://clojars.org/repo",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -226,8 +238,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://clojars.org/repo/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -271,8 +283,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -292,6 +304,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "clojars.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -339,8 +360,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://clojars.org/repo/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -384,8 +405,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -405,6 +426,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "clojars.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -447,8 +477,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://clojars.org/repo/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -492,8 +522,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -513,6 +543,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "clojars.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -536,6 +575,9 @@ Array [
|
||||||
|
|
||||||
exports[`datasource/clojure/index ignores unsupported protocols 1`] = `
|
exports[`datasource/clojure/index ignores unsupported protocols 1`] = `
|
||||||
Array [
|
Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -577,8 +619,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "http://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "http://clojars.org/repo/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -622,8 +664,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "http://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "http://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -643,6 +685,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "http://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "http://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "clojars.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "http://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -672,6 +723,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://custom.registry.renovatebot.com",
|
"registryUrl": "https://custom.registry.renovatebot.com",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -714,8 +768,8 @@ Array [
|
||||||
"host": "custom.registry.renovatebot.com",
|
"host": "custom.registry.renovatebot.com",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://custom.registry.renovatebot.com/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -759,8 +813,8 @@ Array [
|
||||||
"host": "custom.registry.renovatebot.com",
|
"host": "custom.registry.renovatebot.com",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -780,6 +834,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://custom.registry.renovatebot.com/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://custom.registry.renovatebot.com/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "custom.registry.renovatebot.com",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -809,6 +872,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://clojars.org/repo",
|
"registryUrl": "https://clojars.org/repo",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -860,8 +926,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://clojars.org/repo/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -905,8 +971,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -926,6 +992,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "clojars.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -955,6 +1030,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://clojars.org/repo",
|
"registryUrl": "https://clojars.org/repo",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -1006,8 +1084,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://clojars.org/repo/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1051,8 +1129,8 @@ Array [
|
||||||
"host": "clojars.org",
|
"host": "clojars.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1072,6 +1150,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://clojars.org/repo/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "clojars.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://clojars.org/repo/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
|
|
@ -42,6 +42,7 @@ function mockGenericPackage(opts: MockOpts = {}) {
|
||||||
const jars =
|
const jars =
|
||||||
opts.jars === undefined
|
opts.jars === undefined
|
||||||
? {
|
? {
|
||||||
|
'0.0.1': 200,
|
||||||
'1.0.0': 200,
|
'1.0.0': 200,
|
||||||
'1.0.1': 404,
|
'1.0.1': 404,
|
||||||
'1.0.2': 500,
|
'1.0.2': 500,
|
||||||
|
@ -94,9 +95,12 @@ function mockGenericPackage(opts: MockOpts = {}) {
|
||||||
.map((x) => parseInt(x, 10))
|
.map((x) => parseInt(x, 10))
|
||||||
.map((x) => (x < 10 ? `0${x}` : `${x}`));
|
.map((x) => (x < 10 ? `0${x}` : `${x}`));
|
||||||
const timestamp = `2020-01-01T${major}:${minor}:${patch}.000Z`;
|
const timestamp = `2020-01-01T${major}:${minor}:${patch}.000Z`;
|
||||||
|
const headers = version.startsWith('0.')
|
||||||
|
? {}
|
||||||
|
: { 'Last-Modified': timestamp };
|
||||||
scope
|
scope
|
||||||
.head(`/${packagePath}/${version}/${artifact}-${version}.pom`)
|
.head(`/${packagePath}/${version}/${artifact}-${version}.pom`)
|
||||||
.reply(status, '', { 'Last-Modified': timestamp });
|
.reply(status, '', headers);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -188,6 +192,7 @@ describe('datasource/clojure/index', () => {
|
||||||
);
|
);
|
||||||
|
|
||||||
expect(releases).toMatchObject([
|
expect(releases).toMatchObject([
|
||||||
|
{ version: '0.0.1' },
|
||||||
{ version: '1.0.0' },
|
{ version: '1.0.0' },
|
||||||
{ version: '1.0.3-SNAPSHOT' },
|
{ version: '1.0.3-SNAPSHOT' },
|
||||||
{ version: '2.0.0' },
|
{ version: '2.0.0' },
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
<latest>2.0.0</latest>
|
<latest>2.0.0</latest>
|
||||||
<release>2.0.0</release>
|
<release>2.0.0</release>
|
||||||
<versions>
|
<versions>
|
||||||
|
<version>0.0.1</version>
|
||||||
<version>1.0.0</version>
|
<version>1.0.0</version>
|
||||||
<version>1.0.1</version>
|
<version>1.0.1</version>
|
||||||
<version>1.0.2</version>
|
<version>1.0.2</version>
|
||||||
|
|
|
@ -26,8 +26,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -71,8 +71,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -92,6 +92,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -151,6 +160,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://repo.maven.apache.org/maven2",
|
"registryUrl": "https://repo.maven.apache.org/maven2",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -229,8 +241,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -274,8 +286,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -295,6 +307,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -702,8 +723,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -747,8 +768,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -768,6 +789,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -810,8 +840,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -855,8 +885,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -876,6 +906,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -899,6 +938,9 @@ Array [
|
||||||
|
|
||||||
exports[`datasource/maven/index ignores unsupported protocols 1`] = `
|
exports[`datasource/maven/index ignores unsupported protocols 1`] = `
|
||||||
Array [
|
Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -940,8 +982,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "http://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "http://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -985,8 +1027,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "http://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "http://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1006,6 +1048,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "http://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "http://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "http://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -1035,6 +1086,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://frontend_for_private_s3_repository/maven2",
|
"registryUrl": "https://frontend_for_private_s3_repository/maven2",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
},
|
},
|
||||||
|
@ -1125,6 +1179,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://repo.maven.apache.org/maven2",
|
"registryUrl": "https://repo.maven.apache.org/maven2",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -1167,8 +1224,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1212,8 +1269,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1233,6 +1290,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -1262,6 +1328,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://custom.registry.renovatebot.com",
|
"registryUrl": "https://custom.registry.renovatebot.com",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -1307,8 +1376,8 @@ Array [
|
||||||
"host": "custom.registry.renovatebot.com",
|
"host": "custom.registry.renovatebot.com",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://custom.registry.renovatebot.com/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1357,8 +1426,8 @@ Array [
|
||||||
"host": "custom.registry.renovatebot.com",
|
"host": "custom.registry.renovatebot.com",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1380,6 +1449,16 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://custom.registry.renovatebot.com/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://custom.registry.renovatebot.com/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"authorization": "Bearer 123test",
|
||||||
|
"host": "custom.registry.renovatebot.com",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://custom.registry.renovatebot.com/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -1411,6 +1490,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://repo.maven.apache.org/maven2",
|
"registryUrl": "https://repo.maven.apache.org/maven2",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -1462,8 +1544,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1507,8 +1589,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1528,6 +1610,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
@ -1557,6 +1648,9 @@ Object {
|
||||||
"name": "package",
|
"name": "package",
|
||||||
"registryUrl": "https://repo.maven.apache.org/maven2",
|
"registryUrl": "https://repo.maven.apache.org/maven2",
|
||||||
"releases": Array [
|
"releases": Array [
|
||||||
|
Object {
|
||||||
|
"version": "0.0.1",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
"releaseTimestamp": "2020-01-01T01:00:00.000Z",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
|
@ -1608,8 +1702,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "GET",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/0.0.1/package-0.0.1.pom",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1653,8 +1747,8 @@ Array [
|
||||||
"host": "repo.maven.apache.org",
|
"host": "repo.maven.apache.org",
|
||||||
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
},
|
},
|
||||||
"method": "HEAD",
|
"method": "GET",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/maven-metadata.xml",
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
|
@ -1674,6 +1768,15 @@ Array [
|
||||||
"method": "HEAD",
|
"method": "HEAD",
|
||||||
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/2.0.0/package-2.0.0.pom",
|
||||||
},
|
},
|
||||||
|
Object {
|
||||||
|
"headers": Object {
|
||||||
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
"host": "repo.maven.apache.org",
|
||||||
|
"user-agent": "RenovateBot/0.0.0-semantic-release (https://github.com/renovatebot/renovate)",
|
||||||
|
},
|
||||||
|
"method": "HEAD",
|
||||||
|
"url": "https://repo.maven.apache.org/maven2/org/example/package/1.0.4-SNAPSHOT/package-1.0.4-SNAPSHOT.pom",
|
||||||
|
},
|
||||||
Object {
|
Object {
|
||||||
"headers": Object {
|
"headers": Object {
|
||||||
"accept-encoding": "gzip, deflate, br",
|
"accept-encoding": "gzip, deflate, br",
|
||||||
|
|
|
@ -37,6 +37,7 @@ function mockGenericPackage(opts: MockOpts = {}) {
|
||||||
const jars =
|
const jars =
|
||||||
opts.jars === undefined
|
opts.jars === undefined
|
||||||
? {
|
? {
|
||||||
|
'0.0.1': 200,
|
||||||
'1.0.0': 200,
|
'1.0.0': 200,
|
||||||
'1.0.1': 404,
|
'1.0.1': 404,
|
||||||
'1.0.2': 500,
|
'1.0.2': 500,
|
||||||
|
@ -85,9 +86,12 @@ function mockGenericPackage(opts: MockOpts = {}) {
|
||||||
.map((x) => parseInt(x, 10))
|
.map((x) => parseInt(x, 10))
|
||||||
.map((x) => (x < 10 ? `0${x}` : `${x}`));
|
.map((x) => (x < 10 ? `0${x}` : `${x}`));
|
||||||
const timestamp = `2020-01-01T${major}:${minor}:${patch}.000Z`;
|
const timestamp = `2020-01-01T${major}:${minor}:${patch}.000Z`;
|
||||||
|
const headers = version.startsWith('0.')
|
||||||
|
? {}
|
||||||
|
: { 'Last-Modified': timestamp };
|
||||||
scope
|
scope
|
||||||
.head(`/${packagePath}/${version}/${artifact}-${version}.pom`)
|
.head(`/${packagePath}/${version}/${artifact}-${version}.pom`)
|
||||||
.reply(status, '', { 'Last-Modified': timestamp });
|
.reply(status, '', headers);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -201,6 +205,7 @@ describe('datasource/maven/index', () => {
|
||||||
);
|
);
|
||||||
|
|
||||||
expect(releases).toMatchObject([
|
expect(releases).toMatchObject([
|
||||||
|
{ version: '0.0.1' },
|
||||||
{ version: '1.0.0' },
|
{ version: '1.0.0' },
|
||||||
{ version: '1.0.3-SNAPSHOT' },
|
{ version: '1.0.3-SNAPSHOT' },
|
||||||
{ version: '2.0.0' },
|
{ version: '2.0.0' },
|
||||||
|
|
Loading…
Reference in a new issue