Repository: streamlink/streamlink

Issue:
plugins.tv3cat: No plugin can handle URL: https://www.3cat.cat/3cat/directes/tv3/
### Checklist

- [x] This is a [plugin issue](https://streamlink.github.io/plugins.html) and not [a different kind of issue](https://github.com/streamlink/streamlink/issues/new/choose)
- [x] [I have read the contribution guidelines](https://github.com/streamlink/streamlink/blob/master/CONTRIBUTING.md#contributing-to-streamlink)
- [x] [I have checked the list of open and recently closed plugin issues](https://github.com/streamlink/streamlink/issues?q=is%3Aissue+label%3A%22plugin+issue%22)
- [x] [I have checked the commit log of the master branch](https://github.com/streamlink/streamlink/commits/master)

### Collaboration

- [x] [I will provide feedback should a pull request be opened with a fix for the plugin](https://github.com/streamlink/streamlink/blob/master/CONTRIBUTING.md#pull-request-feedback)

### Streamlink version

Latest

### Description

F:\cj_mix>streamlink https://www.3cat.cat/3cat/directes/tv3/
error: No plugin can handle URL: https://www.3cat.cat/3cat/directes/tv3/
TV3 plugin is not working.

### Debug log

F:\cj_mix>streamlink https://www.3cat.cat/3cat/directes/tv3/
error: No plugin can handle URL: https://www.3cat.cat/3cat/directes/tv3/


Discussion:

Patch:
diff --git a/src/streamlink/plugins/tv3cat.py b/src/streamlink/plugins/tv3cat.py
index 40f9f115a16..bd540bb8173 100644
--- a/src/streamlink/plugins/tv3cat.py
+++ b/src/streamlink/plugins/tv3cat.py
@@ -1,5 +1,6 @@
 """
 $description Live TV channels and video on-demand service from CCMA, a Catalan public, state-owned broadcaster.
+$url 3cat.cat
 $url ccma.cat
 $type live, vod
 $region Spain
@@ -21,11 +22,11 @@
 
 @pluginmatcher(
     name="live",
-    pattern=re.compile(r"https://(?:www)?\.ccma\.cat/3cat/directes/(?P<ident>[^/?]+)"),
+    pattern=re.compile(r"https://(?:www)?\.(?:3cat|ccma)\.cat/3cat/directes/(?P<ident>[^/?]+)"),
 )
 @pluginmatcher(
     name="vod",
-    pattern=re.compile(r"https://(?:www)?\.ccma\.cat/3cat/[^/]+/video/(?P<ident>\d+)"),
+    pattern=re.compile(r"https://(?:www)?\.(?:3cat|ccma)\.cat/3cat/[^/]+/video/(?P<ident>\d+)"),
 )
 class TV3Cat(Plugin):
     _URL_API_GEO = "https://dinamics.ccma.cat/geo.json"


Test patch:
diff --git a/tests/plugins/test_tv3cat.py b/tests/plugins/test_tv3cat.py
index 6783d524e95..67a7bb19b23 100644
--- a/tests/plugins/test_tv3cat.py
+++ b/tests/plugins/test_tv3cat.py
@@ -6,12 +6,17 @@ class TestPluginCanHandleUrlTV3Cat(PluginCanHandleUrl):
     __plugin__ = TV3Cat
 
     should_match_groups = [
+        (("live", "https://www.3cat.cat/3cat/directes/tv3/"), {"ident": "tv3"}),
         (("live", "https://www.ccma.cat/3cat/directes/tv3/"), {"ident": "tv3"}),
         (("live", "https://www.ccma.cat/3cat/directes/324/"), {"ident": "324"}),
         (("live", "https://www.ccma.cat/3cat/directes/esport3/"), {"ident": "esport3"}),
         (("live", "https://www.ccma.cat/3cat/directes/sx3/"), {"ident": "sx3"}),
         (("live", "https://www.ccma.cat/3cat/directes/catalunya-radio/"), {"ident": "catalunya-radio"}),
 
+        (
+            ("vod", "https://www.3cat.cat/3cat/t1xc1-arribada/video/6260741/"),
+            {"ident": "6260741"},
+        ),
         (
             ("vod", "https://www.ccma.cat/3cat/t1xc1-arribada/video/6260741/"),
             {"ident": "6260741"},