40 Commits

Author SHA1 Message Date
e87a33eb3f
feat(backend): push posts (#8609)
* push posts

push posts

* unpush posts

* fix comment query

* locales

* fix locales

* fix tests

* Update webapp/locales/de.json

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>

* Update webapp/locales/de.json

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>

* Update webapp/locales/de.json

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>

* fix unpushedSuccessfully english message

* remove paremeters from unpushPost

* rename pushPostToTop -> pushPost, tests

* update locales & tests webapp

* fix lint

---------

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>
2025-06-03 17:57:21 +02:00
Moriz Wahl
a3178a91b4
refactor(webapp): store for categories (#8551)
* after authentification, query the categories if active and store them

* get categories from store

* use category store to get categories

* get categories from store

* mock store to have access to categories

* to get rid of the active categories config variable in the frontend, the Category query returns an empty array when categories are not active

* remove CATEGORIES_ACTIVE from .env

* should return string to avoid warnings in console

* replace all env calls for categories active by getter from store

* use categoriesActive getter

* ignore order of returned categories

* mixin to get the category infos from the store, to ensure, that the quey has been called

* fix misspelling

---------

Co-authored-by: Wolfgang Huß <wolle.huss@pjannto.com>
2025-05-27 15:03:26 +02:00
mahula
7480f2c523 replace deprecated jest methods in webapp unit tests 2023-10-31 11:10:38 +01:00
Wolfgang Huß
4f078e4b24 Fix webapp tests 2023-06-02 10:08:55 +02:00
Wolfgang Huß
1a9c35cb11 Fix webapp tests 2023-06-01 16:26:38 +02:00
Markus
7b1f4cb7e5
Merge branch 'master' into 5982-fix-donation-bar-blink 2023-03-13 17:21:01 +01:00
Markus
f91fd8924e updated unit test for showDonation flag in index page 2023-03-13 10:09:02 +01:00
Moriz Wahl
b2be8a301e first pages test working 2023-02-13 20:29:16 +01:00
ogerly
a6db7e9548 fix test 2023-02-03 08:28:56 +01:00
Moriz Wahl
4535e5d9c5 test category filter by params 2022-11-22 20:06:50 +01:00
Wolfgang Huß
e4a7a6750c Write and fix donations bar frontend tests 2021-05-07 12:14:33 +02:00
Wolfgang Huß
124d752e38 Write tests 2021-05-06 16:59:01 +02:00
Wolfgang Huß
c2cf89447b Rename newsfeed sorting to ordered by
- Fix a test.
2021-04-13 10:16:51 +02:00
Wolfgang Huß
7888d93a7f Cleanup 2021-04-12 15:59:44 +02:00
Wolfgang Huß
245be52ac8 Translate order by
- Cleanup the store.
- Fix tests.
2021-04-12 15:54:56 +02:00
Wolfgang Huß
16d8a42d9b Implement or move sort by date filter in filter menu 2021-04-12 15:09:28 +02:00
mattwr18
06985c2dbb chore: fix lint w/ new linting rules 2020-03-26 18:55:10 +01:00
mattwr18
cb0a3f5cdd chore: Fix lint w/ new linting rules 2020-03-26 10:14:51 +01:00
mattwr18
70bf870e4a chore: update name for HashtagsFilter 2020-03-25 11:02:28 +01:00
Alina Beck
1ffde6bf10 refactor: CategoriesFilter to not use ds-flex
Co-authored-by: mattwr18 <mattwr18@gmail.com>

- introduce LabeledButton component
- rename FilterMenu to HashtagsFilter and FilterPosts to FilterMenu
2020-03-25 11:02:00 +01:00
roschaefer
276ea79e8f Update prettier to v2 2020-03-24 21:11:11 +01:00
Alina Beck
f6cdf9ff64 removes LoadMore button 2019-12-19 08:39:27 +05:30
Alina Beck
a210dd599d Merge branch 'master' into migrate-styleguide-icons 2019-11-20 19:35:03 +03:00
Alina Beck
77f4810ddc set up global localVue
by setting up localVue with all required plugins (such as styleguide and vuex)
in a separate testSetup file we can avoid doing this individually in all component tests
the testSetup is executed before each test suite, so each test file gets a fresh
instance of localVue
2019-11-20 12:31:40 +03:00
roschaefer
950df1cd07 Fix frontend tests
I also removed one frontend test. The test case was checking an edge
case. We use `hasMore` as the single source of truth so I think it's
safe to remove this test case.
2019-11-15 16:20:24 +01:00
mattwr18
f8c5290be0 Clean up following @roschaefer PR review suggestions 2019-11-15 15:23:16 +01:00
mattwr18
7ce3e25110 Merge branch 'master' of github.com:Human-Connection/Human-Connection into donation-info 2019-11-12 21:04:54 +01:00
mattwr18
e19990a58b Fix lint 2019-11-12 13:43:51 +01:00
Moriz Wahl
d7397f5e46 posts/currentPosts now return empty array 2019-11-12 11:20:56 +01:00
mattwr18
cbab34e83c Update test with mock $18n.locale
Co-authored-by: @alina-beck <alina.beck@mail.com>
2019-11-12 10:35:02 +01:00
Moriz Wahl
163825e562 Added Empty Definitions For Missing Getters And Mutations 2019-11-11 21:20:53 +01:00
roschaefer
16d07bd3ba refactor: lint, frontend tests, vuex store
This fixes the lint errors and failing frontend tests. Also, when the
user chooses another orderBy, the menu gets translated.

The refactoring moves code and complexity into the vuex store where it
can be tested separately.
2019-10-18 21:58:53 +02:00
aonomike
34ddd12948 Fix test by setting value of the mocked hashtag
- The test wasnt testing anything as the hashtag value was defaulting to null
- Fixed by setting value of hashtag to a string and then testing if the clearSearch works
2019-09-09 16:22:21 +03:00
Matt Rider
2af4151918 Update to use <client-only> instead of <no-ssr> 2019-08-26 17:09:24 +02:00
Robert Schäfer
f5c939472b Fix console.errors in frontend tests
@MoldaB here's how you can register plugins in a frontend test. Pro tip:
You can run `yarn run test --run-in-band` to find out where the
console.errors come from. Jest, by default, runs in parallel which makes
it a little difficult to debug errors that don't fail the test.
2019-08-15 11:08:42 +02:00
Robert Schäfer
0e707cdd4c Massive refactoring
Fix #1231 the filter menu once and for all...
2019-08-10 03:41:38 +02:00
Robert Schäfer
a8cfe96f60 Don't chane the filterPostsMenu with state
@mattwr18 state is the root of all evil
2019-08-09 17:11:55 +02:00
Matt Rider
e08e150742 Fix bug with lost filter when sorting
- add filtered state to vuex, so as to maintain filter
- filter is reset when visiting other pages, so reset the active buttons in the filter posts dropdown
- maybe we want to maintain the filters between page transitions and only clear when the user requests to?
2019-08-06 10:29:16 +02:00
Matt Rider
ec7a5865f7 Update tests, showFilterPostsDropdown only on route 2019-08-02 15:41:19 +02:00
Matt Rider
88a14ebd4f Add tests, fix typo 2019-07-23 10:55:07 -03:00