Pleroma
\ No newline at end of file
+Pleroma
\ No newline at end of file
diff --git a/priv/static/static/css/app.fd71461124f3eb029b1b.css b/priv/static/static/css/app.ae04505b31bb0ee2765e.css
similarity index 97%
rename from priv/static/static/css/app.fd71461124f3eb029b1b.css
rename to priv/static/static/css/app.ae04505b31bb0ee2765e.css
index 6ab9849ec..05e3f2087 100644
Binary files a/priv/static/static/css/app.fd71461124f3eb029b1b.css and b/priv/static/static/css/app.ae04505b31bb0ee2765e.css differ
diff --git a/priv/static/static/css/app.fd71461124f3eb029b1b.css.map b/priv/static/static/css/app.ae04505b31bb0ee2765e.css.map
similarity index 95%
rename from priv/static/static/css/app.fd71461124f3eb029b1b.css.map
rename to priv/static/static/css/app.ae04505b31bb0ee2765e.css.map
index 660b09d2c..72f33316e 100644
--- a/priv/static/static/css/app.fd71461124f3eb029b1b.css.map
+++ b/priv/static/static/css/app.ae04505b31bb0ee2765e.css.map
@@ -1 +1 @@
-{"version":3,"sources":["webpack:///./src/hocs/with_load_more/with_load_more.scss","webpack:///./src/components/tab_switcher/tab_switcher.scss","webpack:///./src/hocs/with_subscription/with_subscription.scss"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,C;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,C;AClFA;AACA;AACA;AACA;AACA;AACA;AACA,C","file":"static/css/app.fd71461124f3eb029b1b.css","sourcesContent":[".with-load-more-footer {\n padding: 10px;\n text-align: center;\n border-top: 1px solid;\n border-top-color: #222;\n border-top-color: var(--border, #222);\n}\n.with-load-more-footer .error {\n font-size: 14px;\n}",".tab-switcher {\n display: -ms-flexbox;\n display: flex;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.tab-switcher .contents {\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n min-height: 0px;\n}\n.tab-switcher .contents .hidden {\n display: none;\n}\n.tab-switcher .contents.scrollable-tabs {\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n overflow-y: auto;\n}\n.tab-switcher .tabs {\n display: -ms-flexbox;\n display: flex;\n position: relative;\n width: 100%;\n overflow-y: hidden;\n overflow-x: auto;\n padding-top: 5px;\n box-sizing: border-box;\n}\n.tab-switcher .tabs::after, .tab-switcher .tabs::before {\n display: block;\n content: \"\";\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n border-bottom: 1px solid;\n border-bottom-color: #222;\n border-bottom-color: var(--border, #222);\n}\n.tab-switcher .tabs .tab-wrapper {\n height: 28px;\n position: relative;\n display: -ms-flexbox;\n display: flex;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n}\n.tab-switcher .tabs .tab-wrapper .tab {\n width: 100%;\n min-width: 1px;\n position: relative;\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n padding: 6px 1em;\n padding-bottom: 99px;\n margin-bottom: -93px;\n white-space: nowrap;\n}\n.tab-switcher .tabs .tab-wrapper .tab:not(.active) {\n z-index: 4;\n}\n.tab-switcher .tabs .tab-wrapper .tab:not(.active):hover {\n z-index: 6;\n}\n.tab-switcher .tabs .tab-wrapper .tab.active {\n background: transparent;\n z-index: 5;\n}\n.tab-switcher .tabs .tab-wrapper .tab img {\n max-height: 26px;\n vertical-align: top;\n margin-top: -5px;\n}\n.tab-switcher .tabs .tab-wrapper:not(.active)::after {\n content: \"\";\n position: absolute;\n left: 0;\n right: 0;\n bottom: 0;\n z-index: 7;\n border-bottom: 1px solid;\n border-bottom-color: #222;\n border-bottom-color: var(--border, #222);\n}",".with-subscription-loading {\n padding: 10px;\n text-align: center;\n}\n.with-subscription-loading .error {\n font-size: 14px;\n}"],"sourceRoot":""}
\ No newline at end of file
+{"version":3,"sources":["webpack:///./src/hocs/with_load_more/with_load_more.scss","webpack:///./src/components/tab_switcher/tab_switcher.scss","webpack:///./src/hocs/with_subscription/with_subscription.scss"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,C;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,C;AClFA;AACA;AACA;AACA;AACA;AACA;AACA,C","file":"static/css/app.ae04505b31bb0ee2765e.css","sourcesContent":[".with-load-more-footer {\n padding: 10px;\n text-align: center;\n border-top: 1px solid;\n border-top-color: #222;\n border-top-color: var(--border, #222);\n}\n.with-load-more-footer .error {\n font-size: 14px;\n}",".tab-switcher {\n display: -ms-flexbox;\n display: flex;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.tab-switcher .contents {\n -ms-flex: 1 0 auto;\n flex: 1 0 auto;\n min-height: 0px;\n}\n.tab-switcher .contents .hidden {\n display: none;\n}\n.tab-switcher .contents.scrollable-tabs {\n -ms-flex-preferred-size: 0;\n flex-basis: 0;\n overflow-y: auto;\n}\n.tab-switcher .tabs {\n display: -ms-flexbox;\n display: flex;\n position: relative;\n width: 100%;\n overflow-y: hidden;\n overflow-x: auto;\n padding-top: 5px;\n box-sizing: border-box;\n}\n.tab-switcher .tabs::after, .tab-switcher .tabs::before {\n display: block;\n content: \"\";\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n border-bottom: 1px solid;\n border-bottom-color: #222;\n border-bottom-color: var(--border, #222);\n}\n.tab-switcher .tabs .tab-wrapper {\n height: 28px;\n position: relative;\n display: -ms-flexbox;\n display: flex;\n -ms-flex: 0 0 auto;\n flex: 0 0 auto;\n}\n.tab-switcher .tabs .tab-wrapper .tab {\n width: 100%;\n min-width: 1px;\n position: relative;\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n padding: 6px 1em;\n padding-bottom: 99px;\n margin-bottom: -93px;\n white-space: nowrap;\n}\n.tab-switcher .tabs .tab-wrapper .tab:not(.active) {\n z-index: 4;\n}\n.tab-switcher .tabs .tab-wrapper .tab:not(.active):hover {\n z-index: 6;\n}\n.tab-switcher .tabs .tab-wrapper .tab.active {\n background: transparent;\n z-index: 5;\n}\n.tab-switcher .tabs .tab-wrapper .tab img {\n max-height: 26px;\n vertical-align: top;\n margin-top: -5px;\n}\n.tab-switcher .tabs .tab-wrapper:not(.active)::after {\n content: \"\";\n position: absolute;\n left: 0;\n right: 0;\n bottom: 0;\n z-index: 7;\n border-bottom: 1px solid;\n border-bottom-color: #222;\n border-bottom-color: var(--border, #222);\n}",".with-subscription-loading {\n padding: 10px;\n text-align: center;\n}\n.with-subscription-loading .error {\n font-size: 14px;\n}"],"sourceRoot":""}
\ No newline at end of file
diff --git a/priv/static/static/font/LICENSE.txt b/priv/static/static/font/LICENSE.txt
deleted file mode 100755
index 95966f00e..000000000
--- a/priv/static/static/font/LICENSE.txt
+++ /dev/null
@@ -1,39 +0,0 @@
-Font license info
-
-
-## Font Awesome
-
- Copyright (C) 2016 by Dave Gandy
-
- Author: Dave Gandy
- License: SIL ()
- Homepage: http://fortawesome.github.com/Font-Awesome/
-
-
-## Entypo
-
- Copyright (C) 2012 by Daniel Bruce
-
- Author: Daniel Bruce
- License: SIL (http://scripts.sil.org/OFL)
- Homepage: http://www.entypo.com
-
-
-## Iconic
-
- Copyright (C) 2012 by P.J. Onori
-
- Author: P.J. Onori
- License: SIL (http://scripts.sil.org/OFL)
- Homepage: http://somerandomdude.com/work/iconic/
-
-
-## Fontelico
-
- Copyright (C) 2012 by Fontello project
-
- Author: Crowdsourced, for Fontello project
- License: SIL (http://scripts.sil.org/OFL)
- Homepage: http://fontello.com
-
-
diff --git a/priv/static/static/font/README.txt b/priv/static/static/font/README.txt
deleted file mode 100755
index beaab3366..000000000
--- a/priv/static/static/font/README.txt
+++ /dev/null
@@ -1,75 +0,0 @@
-This webfont is generated by http://fontello.com open source project.
-
-
-================================================================================
-Please, note, that you should obey original font licenses, used to make this
-webfont pack. Details available in LICENSE.txt file.
-
-- Usually, it's enough to publish content of LICENSE.txt file somewhere on your
- site in "About" section.
-
-- If your project is open-source, usually, it will be ok to make LICENSE.txt
- file publicly available in your repository.
-
-- Fonts, used in Fontello, don't require a clickable link on your site.
- But any kind of additional authors crediting is welcome.
-================================================================================
-
-
-Comments on archive content
----------------------------
-
-- /font/* - fonts in different formats
-
-- /css/* - different kinds of css, for all situations. Should be ok with
- twitter bootstrap. Also, you can skip style and assign icon classes
- directly to text elements, if you don't mind about IE7.
-
-- demo.html - demo file, to show your webfont content
-
-- LICENSE.txt - license info about source fonts, used to build your one.
-
-- config.json - keeps your settings. You can import it back into fontello
- anytime, to continue your work
-
-
-Why so many CSS files ?
------------------------
-
-Because we like to fit all your needs :)
-
-- basic file, .css - is usually enough, it contains @font-face
- and character code definitions
-
-- *-ie7.css - if you need IE7 support, but still don't wish to put char codes
- directly into html
-
-- *-codes.css and *-ie7-codes.css - if you like to use your own @font-face
- rules, but still wish to benefit from css generation. That can be very
- convenient for automated asset build systems. When you need to update font -
- no need to manually edit files, just override old version with archive
- content. See fontello source code for examples.
-
-- *-embedded.css - basic css file, but with embedded WOFF font, to avoid
- CORS issues in Firefox and IE9+, when fonts are hosted on the separate domain.
- We strongly recommend to resolve this issue by `Access-Control-Allow-Origin`
- server headers. But if you ok with dirty hack - this file is for you. Note,
- that data url moved to separate @font-face to avoid problems with
-
-
-
-
-
-
-
-
-
fontello font demo
-
-
-
-
-
icon-cancel0xe800
-
icon-upload0xe801
-
icon-star0xe802
-
icon-star-empty0xe803
-
-
-
icon-retweet0xe804
-
icon-eye-off0xe805
-
icon-search0xe806
-
icon-cog0xe807
-
-
-
icon-logout0xe808
-
icon-down-open0xe809
-
icon-attach0xe80a
-
icon-picture0xe80b
-
-
-
icon-video0xe80c
-
icon-right-open0xe80d
-
icon-left-open0xe80e
-
icon-up-open0xe80f
-
-
-
icon-bell-ringing-o0xe810
-
icon-lock0xe811
-
icon-globe0xe812
-
icon-brush0xe813
-
-
-
icon-attention0xe814
-
icon-plus0xe815
-
icon-adjust0xe816
-
icon-edit0xe817
-
-
-
icon-pencil0xe818
-
icon-pin0xe819
-
icon-wrench0xe81a
-
icon-chart-bar0xe81b
-
-
-
icon-zoom-in0xe81c
-
icon-spin30xe832
-
icon-spin40xe834
-
icon-link-ext0xf08e
-
-
-
icon-link-ext-alt0xf08f
-
icon-menu0xf0c9
-
icon-mail-alt0xf0e0
-
icon-gauge0xf0e4
-
-
-
icon-comment-empty0xf0e5
-
icon-bell-alt0xf0f3
-
icon-plus-squared0xf0fe
-
icon-reply0xf112
-
-
-
icon-smile0xf118
-
icon-lock-open-alt0xf13e
-
icon-ellipsis0xf141
-
icon-play-circled0xf144
-
-
-
icon-thumbs-up-alt0xf164
-
icon-binoculars0xf1e5
-
icon-user-plus0xf234
-
-
-
-
-
\ No newline at end of file
diff --git a/priv/static/static/font/font/fontello.woff b/priv/static/static/font/font/fontello.woff
deleted file mode 100755
index 1d5025d3c..000000000
Binary files a/priv/static/static/font/font/fontello.woff and /dev/null differ
diff --git a/priv/static/static/font/font/fontello.woff2 b/priv/static/static/font/font/fontello.woff2
deleted file mode 100755
index 078991eb8..000000000
Binary files a/priv/static/static/font/font/fontello.woff2 and /dev/null differ
diff --git a/priv/static/static/font/font/fontello.eot b/priv/static/static/font/fontello.1576263574934.eot
old mode 100755
new mode 100644
similarity index 81%
rename from priv/static/static/font/font/fontello.eot
rename to priv/static/static/font/fontello.1576263574934.eot
index 1703fd97f..9bd04cccb
Binary files a/priv/static/static/font/font/fontello.eot and b/priv/static/static/font/fontello.1576263574934.eot differ
diff --git a/priv/static/static/font/font/fontello.svg b/priv/static/static/font/fontello.1576263574934.svg
old mode 100755
new mode 100644
similarity index 90%
rename from priv/static/static/font/font/fontello.svg
rename to priv/static/static/font/fontello.1576263574934.svg
index f5e497ce4..7850869b8
--- a/priv/static/static/font/font/fontello.svg
+++ b/priv/static/static/font/fontello.1576263574934.svg
@@ -64,6 +64,16 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/priv/static/static/font/font/fontello.ttf b/priv/static/static/font/fontello.1576263574934.ttf
old mode 100755
new mode 100644
similarity index 81%
rename from priv/static/static/font/font/fontello.ttf
rename to priv/static/static/font/fontello.1576263574934.ttf
index e9ed78031..2c4829830
Binary files a/priv/static/static/font/font/fontello.ttf and b/priv/static/static/font/fontello.1576263574934.ttf differ
diff --git a/priv/static/static/font/fontello.1576263574934.woff b/priv/static/static/font/fontello.1576263574934.woff
new file mode 100644
index 000000000..05f5d69dc
Binary files /dev/null and b/priv/static/static/font/fontello.1576263574934.woff differ
diff --git a/priv/static/static/font/fontello.1576263574934.woff2 b/priv/static/static/font/fontello.1576263574934.woff2
new file mode 100644
index 000000000..f542d0f00
Binary files /dev/null and b/priv/static/static/font/fontello.1576263574934.woff2 differ
diff --git a/priv/static/static/fontello.1576263574934.css b/priv/static/static/fontello.1576263574934.css
new file mode 100644
index 000000000..c1c120f5b
Binary files /dev/null and b/priv/static/static/fontello.1576263574934.css differ
diff --git a/priv/static/static/font/config.json b/priv/static/static/fontello.json
similarity index 92%
rename from priv/static/static/font/config.json
rename to priv/static/static/fontello.json
index c0cf17271..c1ed33938 100755
--- a/priv/static/static/font/config.json
+++ b/priv/static/static/fontello.json
@@ -303,6 +303,36 @@
"css": "gauge",
"code": 61668,
"src": "fontawesome"
+ },
+ {
+ "uid": "31972e4e9d080eaa796290349ae6c1fd",
+ "css": "users",
+ "code": 59421,
+ "src": "fontawesome"
+ },
+ {
+ "uid": "e82cedfa1d5f15b00c5a81c9bd731ea2",
+ "css": "info-circled",
+ "code": 59423,
+ "src": "fontawesome"
+ },
+ {
+ "uid": "w3nzesrlbezu6f30q7ytyq919p6gdlb6",
+ "css": "home-2",
+ "code": 59425,
+ "src": "typicons"
+ },
+ {
+ "uid": "dcedf50ab1ede3283d7a6c70e2fe32f3",
+ "css": "chat",
+ "code": 59422,
+ "src": "fontawesome"
+ },
+ {
+ "uid": "3a00327e61b997b58518bd43ed83c3df",
+ "css": "login",
+ "code": 59424,
+ "src": "fontawesome"
}
]
}
\ No newline at end of file
diff --git a/priv/static/static/js/2.9f2ac5e61b4f3efacd6b.js b/priv/static/static/js/2.9f2ac5e61b4f3efacd6b.js
new file mode 100644
index 000000000..d11edf4aa
Binary files /dev/null and b/priv/static/static/js/2.9f2ac5e61b4f3efacd6b.js differ
diff --git a/priv/static/static/js/2.9f2ac5e61b4f3efacd6b.js.map b/priv/static/static/js/2.9f2ac5e61b4f3efacd6b.js.map
new file mode 100644
index 000000000..52ac52700
Binary files /dev/null and b/priv/static/static/js/2.9f2ac5e61b4f3efacd6b.js.map differ
diff --git a/priv/static/static/js/2.c96b30ae9f2d3f46f0ad.js b/priv/static/static/js/2.c96b30ae9f2d3f46f0ad.js
deleted file mode 100644
index 910d304d3..000000000
Binary files a/priv/static/static/js/2.c96b30ae9f2d3f46f0ad.js and /dev/null differ
diff --git a/priv/static/static/js/2.c96b30ae9f2d3f46f0ad.js.map b/priv/static/static/js/2.c96b30ae9f2d3f46f0ad.js.map
deleted file mode 100644
index 25e514a5b..000000000
Binary files a/priv/static/static/js/2.c96b30ae9f2d3f46f0ad.js.map and /dev/null differ
diff --git a/priv/static/static/js/app.d20ca27d22d74eb7bce0.js b/priv/static/static/js/app.d20ca27d22d74eb7bce0.js
deleted file mode 100644
index 7abf2ec28..000000000
Binary files a/priv/static/static/js/app.d20ca27d22d74eb7bce0.js and /dev/null differ
diff --git a/priv/static/static/js/app.d20ca27d22d74eb7bce0.js.map b/priv/static/static/js/app.d20ca27d22d74eb7bce0.js.map
deleted file mode 100644
index 6c96ca5b2..000000000
Binary files a/priv/static/static/js/app.d20ca27d22d74eb7bce0.js.map and /dev/null differ
diff --git a/priv/static/static/js/app.e63654e5ca9fff82f59d.js b/priv/static/static/js/app.e63654e5ca9fff82f59d.js
new file mode 100644
index 000000000..f98bc65bd
Binary files /dev/null and b/priv/static/static/js/app.e63654e5ca9fff82f59d.js differ
diff --git a/priv/static/static/js/app.e63654e5ca9fff82f59d.js.map b/priv/static/static/js/app.e63654e5ca9fff82f59d.js.map
new file mode 100644
index 000000000..e7050519b
Binary files /dev/null and b/priv/static/static/js/app.e63654e5ca9fff82f59d.js.map differ
diff --git a/priv/static/static/js/vendors~app.76db8e4cdf29decd5cab.js b/priv/static/static/js/vendors~app.76db8e4cdf29decd5cab.js
deleted file mode 100644
index 135bdebb3..000000000
Binary files a/priv/static/static/js/vendors~app.76db8e4cdf29decd5cab.js and /dev/null differ
diff --git a/priv/static/static/js/vendors~app.76db8e4cdf29decd5cab.js.map b/priv/static/static/js/vendors~app.76db8e4cdf29decd5cab.js.map
deleted file mode 100644
index 6513c0a0b..000000000
Binary files a/priv/static/static/js/vendors~app.76db8e4cdf29decd5cab.js.map and /dev/null differ
diff --git a/priv/static/static/js/vendors~app.82d2415271fd2bf6bdfd.js b/priv/static/static/js/vendors~app.82d2415271fd2bf6bdfd.js
new file mode 100644
index 000000000..bfb23c17c
Binary files /dev/null and b/priv/static/static/js/vendors~app.82d2415271fd2bf6bdfd.js differ
diff --git a/priv/static/static/js/vendors~app.82d2415271fd2bf6bdfd.js.map b/priv/static/static/js/vendors~app.82d2415271fd2bf6bdfd.js.map
new file mode 100644
index 000000000..848ef7c31
Binary files /dev/null and b/priv/static/static/js/vendors~app.82d2415271fd2bf6bdfd.js.map differ
diff --git a/priv/static/sw-pleroma.js b/priv/static/sw-pleroma.js
index 276af8173..a958ae9a5 100644
Binary files a/priv/static/sw-pleroma.js and b/priv/static/sw-pleroma.js differ
diff --git a/priv/static/sw-pleroma.js.map b/priv/static/sw-pleroma.js.map
index 1ac8d8676..5d9874693 100644
Binary files a/priv/static/sw-pleroma.js.map and b/priv/static/sw-pleroma.js.map differ
diff --git a/rel/env.sh.eex b/rel/env.sh.eex
index a4ce25295..e1b87102d 100644
--- a/rel/env.sh.eex
+++ b/rel/env.sh.eex
@@ -8,5 +8,5 @@
# fi
# Set the release to work across nodes
-export RELEASE_DISTRIBUTION=name
-export RELEASE_NODE=<%= @release.name %>@127.0.0.1
+export RELEASE_DISTRIBUTION="${RELEASE_DISTRIBUTION:-name}"
+export RELEASE_NODE="${RELEASE_NODE:-<%= @release.name %>@127.0.0.1}"
diff --git a/test/captcha_test.exs b/test/captcha_test.exs
index 7ca9a4607..d9ead3299 100644
--- a/test/captcha_test.exs
+++ b/test/captcha_test.exs
@@ -8,6 +8,7 @@ defmodule Pleroma.CaptchaTest do
import Tesla.Mock
alias Pleroma.Captcha.Kocaptcha
+ alias Pleroma.Captcha.Native
@ets_options [:ordered_set, :private, :named_table, {:read_concurrency, true}]
@@ -43,4 +44,21 @@ test "new and validate" do
) == :ok
end
end
+
+ describe "Native" do
+ test "new and validate" do
+ new = Native.new()
+
+ assert %{
+ answer_data: answer,
+ token: token,
+ type: :native,
+ url: "data:image/png;base64," <> _
+ } = new
+
+ assert is_binary(answer)
+ assert :ok = Native.validate(token, answer, answer)
+ assert {:error, "Invalid CAPTCHA"} == Native.validate(token, answer, answer <> "foobar")
+ end
+ end
end
diff --git a/test/plugs/cache_control_test.exs b/test/plugs/cache_control_test.exs
index 45151b289..8f0af264e 100644
--- a/test/plugs/cache_control_test.exs
+++ b/test/plugs/cache_control_test.exs
@@ -9,7 +9,7 @@ defmodule Pleroma.Web.CacheControlTest do
test "Verify Cache-Control header on static assets", %{conn: conn} do
conn = get(conn, "/index.html")
- assert Conn.get_resp_header(conn, "cache-control") == ["public, no-cache"]
+ assert Conn.get_resp_header(conn, "cache-control") == ["public max-age=86400 must-revalidate"]
end
test "Verify Cache-Control header on the API", %{conn: conn} do
diff --git a/test/user_search_test.exs b/test/user_search_test.exs
index 6ee624929..cf2da8767 100644
--- a/test/user_search_test.exs
+++ b/test/user_search_test.exs
@@ -51,13 +51,6 @@ test "finds a user by full or partial name" do
end)
end
- test "finds users, preferring nickname matches over name matches" do
- u1 = insert(:user, %{name: "lain", nickname: "nick1"})
- u2 = insert(:user, %{nickname: "lain", name: "nick1"})
-
- assert [u2.id, u1.id] == Enum.map(User.search("lain"), & &1.id)
- end
-
test "finds users, considering density of matched tokens" do
u1 = insert(:user, %{name: "Bar Bar plus Word Word"})
u2 = insert(:user, %{name: "Word Word Bar Bar Bar"})
diff --git a/test/web/node_info_test.exs b/test/web/node_info_test.exs
index f6147c286..4edcdaf60 100644
--- a/test/web/node_info_test.exs
+++ b/test/web/node_info_test.exs
@@ -84,6 +84,30 @@ test "it returns the safe_dm_mentions feature if enabled", %{conn: conn} do
Pleroma.Config.put([:instance, :safe_dm_mentions], option)
end
+ test "it shows if federation is enabled/disabled", %{conn: conn} do
+ original = Pleroma.Config.get([:instance, :federating])
+
+ Pleroma.Config.put([:instance, :federating], true)
+
+ response =
+ conn
+ |> get("/nodeinfo/2.1.json")
+ |> json_response(:ok)
+
+ assert response["metadata"]["federation"]["enabled"] == true
+
+ Pleroma.Config.put([:instance, :federating], false)
+
+ response =
+ conn
+ |> get("/nodeinfo/2.1.json")
+ |> json_response(:ok)
+
+ assert response["metadata"]["federation"]["enabled"] == false
+
+ Pleroma.Config.put([:instance, :federating], original)
+ end
+
test "it shows MRF transparency data if enabled", %{conn: conn} do
config = Pleroma.Config.get([:instance, :rewrite_policy])
Pleroma.Config.put([:instance, :rewrite_policy], [Pleroma.Web.ActivityPub.MRF.SimplePolicy])