Compare commits

..

No commits in common. "cb1dc994d76277a0f6fcf4750ccffcdf179b8a5f" and "66460789449be0d5984cbdb6ec372e69323b7a88" have entirely different histories.

9 changed files with 82 additions and 107 deletions

View file

@ -28,10 +28,3 @@ jobs:
with:
name: test
path: target/nextest/ci/junit.xml
- name: 🔗 Artifactview PR comment
if: ${{ always() && github.event_name == 'pull_request' }}
run: |
if [[ "$GITEA_ACTIONS" == "true" ]]; then RUN_NUMBER="$GITHUB_RUN_NUMBER"; else RUN_NUMBER="$GITHUB_RUN_ID"; fi
curl -SsL --fail-with-body -w "\n" -X POST https://av.thetadev.de/.well-known/api/prComment -H "Content-Type: application/json" \
--data '{"url": "'"$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$RUN_NUMBER"'", "pr": ${{ github.event.number }}}'

View file

@ -1,15 +1,15 @@
test:
# cargo test --features=rss
cargo nextest run --features=rss --no-fail-fast --failure-output final --retries 1
cargo nextest run --features=rss --no-fail-fast --failure-output final
unittest:
cargo nextest run --features=rss --no-fail-fast --failure-output final --lib
testyt:
cargo nextest run --features=rss --no-fail-fast --failure-output final --retries 1 --test youtube
cargo nextest run --features=rss --no-fail-fast --failure-output final --test youtube
testyt-localized:
YT_LANG=th cargo nextest run --features=rss --no-fail-fast --failure-output final --retries 1 --test youtube
YT_LANG=th cargo nextest run --features=rss --no-fail-fast --failure-output final --test youtube
testintl:
#!/usr/bin/env bash
@ -28,7 +28,7 @@ testintl:
for YT_LANG in "${LANGUAGES[@]}"; do
echo "---TESTS FOR $YT_LANG ---"
if YT_LANG="$YT_LANG" cargo nextest run --no-fail-fast --failure-output final --retries 1 --test-threads 4 --test youtube -E 'not test(/^resolve/)'; then
if YT_LANG="$YT_LANG" cargo test --test youtube -- --test-threads 4 --skip resolve; then
echo "--- $YT_LANG COMPLETED ---"
else
echo "--- $YT_LANG FAILED ---"

View file

@ -159,7 +159,6 @@ Subscribers: 1780000
- Current version of stable Rust
- [`just`](https://github.com/casey/just) task runner
- [`nextest`](https://nexte.st) test runner
- [`pre-commit`](https://pre-commit.com/)
- yq (YAML processor)

View file

@ -5418,16 +5418,16 @@ pub(crate) fn entry(lang: Language) -> Entry {
],
},
album_types: ::phf::Map {
key: 15467950696543387533,
key: 12913932095322966823,
disps: &[
(2, 0),
(1, 0),
],
entries: &[
("álbum", AlbumType::Album),
("ep", AlbumType::Ep),
("single", AlbumType::Single),
("ep", AlbumType::Ep),
("programa", AlbumType::Show),
("audiolivro", AlbumType::Audiobook),
("livro áudio", AlbumType::Audiobook),
],
},
},

View file

@ -3184,7 +3184,7 @@
"number_nd_tokens": {},
"album_types": {
"álbum": "Album",
"audiolivro": "Audiobook",
"livro áudio": "Audiobook",
"ep": "Ep",
"programa": "Show",
"single": "Single"

View file

@ -16,21 +16,7 @@ MusicAlbum(
artist_id: Some("UCwem2sj-QUJCiWiPAo9JuAw"),
description: Some(RichText([
Text(
text: "Unbroken is the third studio album by American singer Demi Lovato. It was released on September 20, 2011, by Hollywood Records. Primarily a pop record, Lovato described the album as \"more mature\" and with more R&B elements than her previous material, citing Rihanna as the major influence. While some of the album\'s lyrical content was heavily influenced by Lovato\'s personal struggles, it also deals with lighter subjects, such as love and self empowerment. Contributions to the album\'s production came from a wide range of producers, including Toby Gad, Ryan Tedder, Timbaland, Jim Beanz and Rock Mafia.\nLovato initially began recording her third studio album in 2010 before going on tour with the Jonas Brothers on their Live in Concert Tour. After withdrawing from the tour to seek treatment for physical and emotional issues, Lovato continued work on the album and described the recording process as therapeutic. She collaborated with artists such as Missy Elliott, Timbaland, Dev, Iyaz, and Jason Derulo on several tracks.\n\nFrom Wikipedia (",
),
Web(
text: "https://en.wikipedia.org/wiki/Unbroke...",
url: "https://en.wikipedia.org/wiki/Unbroken_(Demi_Lovato_album)",
),
Text(
text: ") under Creative Commons Attribution CC-BY-SA 3.0 (",
),
Web(
text: "https://creativecommons.org/licenses/...",
url: "https://creativecommons.org/licenses/by-sa/3.0/legalcode",
),
Text(
text: ")",
text: "Unbroken is the third studio album by American singer Demi Lovato. It was released on September 20, 2011, by Hollywood Records. Primarily a pop record, Lovato described the album as \"more mature\" and with more R&B elements than her previous material, citing Rihanna as the major influence. While some of the album\'s lyrical content was heavily influenced by Lovato\'s personal struggles, it also deals with lighter subjects, such as love and self empowerment. Contributions to the album\'s production came from a wide range of producers, including Toby Gad, Ryan Tedder, Timbaland, Jim Beanz and Rock Mafia.\nLovato initially began recording her third studio album in 2010 before going on tour with the Jonas Brothers on their Live in Concert Tour. After withdrawing from the tour to seek treatment for physical and emotional issues, Lovato continued work on the album and described the recording process as therapeutic. She collaborated with artists such as Missy Elliott, Timbaland, Dev, Iyaz, and Jason Derulo on several tracks.\n\nFrom Wikipedia (https://en.wikipedia.org/wiki/Unbroken_(Demi_Lovato_album)) under Creative Commons Attribution CC-BY-SA 3.0 (https://creativecommons.org/licenses/by-sa/3.0/legalcode)",
),
])),
album_type: Album,

View file

@ -42,8 +42,8 @@ MusicArtist(
by_va: false,
),
AlbumItem(
id: "MPREb_HrCgErOdgCv",
name: "Freiheit",
id: "MPREb_6PEkIQE7sWY",
name: "An deiner Seite (Online Version)",
cover: "[cover]",
artists: [
ArtistId(
@ -52,8 +52,8 @@ MusicArtist(
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Album,
year: Some(2004),
album_type: Ep,
year: Some(2008),
by_va: false,
),
AlbumItem(
@ -101,6 +101,21 @@ MusicArtist(
year: Some(2012),
by_va: false,
),
AlbumItem(
id: "MPREb_QyGCcLWExXj",
name: "Als wär\'s das erste Mal (Exklusive Piano Version)",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "Unheilig",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Single,
year: Some(2014),
by_va: false,
),
AlbumItem(
id: "MPREb_R3p5kDRIGKL",
name: "Astronaut",
@ -191,21 +206,6 @@ MusicArtist(
year: Some(2021),
by_va: false,
),
AlbumItem(
id: "MPREb_bUKkpmkyv9M",
name: "Als wär\'s das erste Mal",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "Unheilig",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Single,
year: Some(2014),
by_va: false,
),
AlbumItem(
id: "MPREb_f4MhYbccbPi",
name: "Moderne Zeiten",
@ -251,21 +251,6 @@ MusicArtist(
year: Some(2015),
by_va: false,
),
AlbumItem(
id: "MPREb_ohcGTZrqKPZ",
name: "Zelluloid",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "Unheilig",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Album,
year: Some(2004),
by_va: false,
),
AlbumItem(
id: "MPREb_pWpeXxATZYb",
name: "Wir sind alle wie eins",
@ -281,6 +266,21 @@ MusicArtist(
year: Some(2014),
by_va: false,
),
AlbumItem(
id: "MPREb_rHhaDLqalbT",
name: "Winter (EP)",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "Unheilig",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Ep,
year: Some(2010),
by_va: false,
),
AlbumItem(
id: "MPREb_saXgTKNPaSu",
name: "Zeit zu gehen",

View file

@ -42,7 +42,7 @@ MusicArtist(
by_va: false,
),
AlbumItem(
id: "MPREb_HrCgErOdgCv",
id: "MPREb_6PEkIQE7sWY",
name: "[name]",
cover: "[cover]",
artists: [
@ -52,8 +52,8 @@ MusicArtist(
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Album,
year: Some(2004),
album_type: Ep,
year: Some(2008),
by_va: false,
),
AlbumItem(
@ -101,6 +101,21 @@ MusicArtist(
year: Some(2012),
by_va: false,
),
AlbumItem(
id: "MPREb_QyGCcLWExXj",
name: "[name]",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "[name]",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Single,
year: Some(2014),
by_va: false,
),
AlbumItem(
id: "MPREb_R3p5kDRIGKL",
name: "[name]",
@ -191,21 +206,6 @@ MusicArtist(
year: Some(2021),
by_va: false,
),
AlbumItem(
id: "MPREb_bUKkpmkyv9M",
name: "[name]",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "[name]",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Single,
year: Some(2014),
by_va: false,
),
AlbumItem(
id: "MPREb_f4MhYbccbPi",
name: "[name]",
@ -251,21 +251,6 @@ MusicArtist(
year: Some(2015),
by_va: false,
),
AlbumItem(
id: "MPREb_ohcGTZrqKPZ",
name: "[name]",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "[name]",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Album,
year: Some(2004),
by_va: false,
),
AlbumItem(
id: "MPREb_pWpeXxATZYb",
name: "[name]",
@ -281,6 +266,21 @@ MusicArtist(
year: Some(2014),
by_va: false,
),
AlbumItem(
id: "MPREb_rHhaDLqalbT",
name: "[name]",
cover: "[cover]",
artists: [
ArtistId(
id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
name: "[name]",
),
],
artist_id: Some("UC7cl4MmM6ZZ2TcFyMk_b4pg"),
album_type: Ep,
year: Some(2010),
by_va: false,
),
AlbumItem(
id: "MPREb_saXgTKNPaSu",
name: "[name]",

View file

@ -352,7 +352,7 @@ async fn get_player_error_paid(rp: RustyPipe) {
#[rstest]
#[case::long(
"PL5dDx681T4bR7ZF1IuWzOv1omlRbE7PiJ",
"Die schönsten deutschen Lieder | Beliebteste Lieder | Beste Deutsche Musik 2020 2022",
"Die schönsten deutschen Lieder | Beliebteste Lieder | Beste Deutsche Musik 2022",
true,
None,
Some(("UCIekuFeMaV78xYfvpmoCnPg", "Best Music")),
@ -1464,7 +1464,7 @@ async fn trending(rp: RustyPipe) {
#[rstest]
#[case::long(
"PL5dDx681T4bR7ZF1IuWzOv1omlRbE7PiJ",
"Die schönsten deutschen Lieder | Beliebteste Lieder | Beste Deutsche Musik 2020 2022",
"Die schönsten deutschen Lieder | Beliebteste Lieder | Beste Deutsche Musik 2022",
true,
None,
Some(("UCIekuFeMaV78xYfvpmoCnPg", "Best Music")),
@ -1630,7 +1630,7 @@ async fn music_album_not_found(rp: RustyPipe) {
#[rstest]
#[case::basic_all("basic_all", "UCFKUUtHjT4iq3p0JJA13SOA", true, 15, 1)]
#[case::basic("basic", "UC7cl4MmM6ZZ2TcFyMk_b4pg", false, 15, 0)]
#[case::basic("basic", "UC7cl4MmM6ZZ2TcFyMk_b4pg", false, 15, 2)]
#[case::no_more_albums("no_more_albums", "UCOR4_bSVIXPsGa4BbCSt60Q", true, 15, 0)]
#[case::only_singles("only_singles", "UCfwCE5VhPMGxNPFxtVv7lRw", false, 13, 0)]
#[case::no_artist("no_artist", "UCh8gHdtzO2tXd593_bjErWg", false, 0, 0)]
@ -2187,8 +2187,7 @@ async fn music_search_genre_radio(rp: RustyPipe) {
}
#[rstest]
// TODO: reenable when music search suggestions work again
// #[case::default("ed sheer", Some("ed sheeran"), Some("UClmXPfaYhXOYsNn_QUyheWQ"))]
#[case::default("ed sheer", Some("ed sheeran"), Some("UClmXPfaYhXOYsNn_QUyheWQ"))]
#[case::empty("reujbhevmfndxnjrze", None, None)]
#[tokio::test]
async fn music_search_suggestion(
@ -2549,9 +2548,7 @@ async fn music_genres(rp: RustyPipe, unlocalized: bool) {
.iter()
.find(|g| g.id == "ggMPOg1uX1lMbVZmbzl6NlJ3" || g.id == "ggMPOg1uX1BmNzc2V2p0YXJ5")
.expect("genre: Pop");
if unlocalized {
assert_eq!(pop.name, "Pop");
}
assert_eq!(pop.name, "Pop");
assert!(!pop.is_mood);
for g in &genres {