summaryrefslogtreecommitdiffstats
path: root/api4/channel_test.go
Commit message (Collapse)AuthorAgeFilesLines
* MM-9664 Add invalidation metrics for store caches (#8340)Joram Wilander2018-03-051-4/+3
| | | | | | | | * Add invalidation metrics for store caches * Increment session invalidation metric * Fix tests
* Eliminate utils.SetLicense calls (#8217)Chris2018-02-071-135/+13
| | | | | | | | | | * eliminate utils.SetLicense calls * test fix * another test fix * more test fixes
* [PLT-8430] Auto lowercase team and channel names in API requests (#7992)Carlos Tadeu Panato Junior2018-01-121-0/+4
|
* Role refactor (#7867)Chris2017-11-211-24/+24
| | | | | | | | * role refactor * add missing file * fix web test
* [PLT-7362] Add post' root ID to APIv4 addChannelMember to render added user ↵Saturnino Abril2017-10-311-0/+18
| | | | | | | | | | (as system post) at RHS (#7730) * add post' root ID to apiv4 addChannelMember to render added user (as system post) at RHS * add check to post_root_id parameter * add AddChannelMemberWithRootId function for backward compatibility
* Reduce utils.Cfg references (#7650)Chris2017-10-181-36/+76
| | | | | | | | | | | | * app.UpdateConfig method * test fix * another test fix * the config override option as-was is just error prone, remove it for now * derp
* PLT-7718 Patch for files (#7564)Joram Wilander2017-10-041-1/+1
| | | | | | | | | | * Patch for files * Fix merge * Fix tests * Fix another test
* Don't use global app for api / api4 tests (#7528)Chris2017-10-021-43/+43
| | | | | | | | | | | | | | * don't use global app for api / api4 tests * put sleep back. we're gonna have to do some goroutine wrangling * fix oauth test config assumptions * jobs package, i'm comin' for you next * app test fix * try increasing sleep a little
* PLT-7404 Return viewed at times in view channel API response (#7428)Joram Wilander2017-09-291-3/+9
| | | | | | | | * Return viewed at times in view channel API response * Updated transaction to read and write once * Remove transaction and only update if new value greater than older
* Move sql store code into store/sqlstore package (#7502)Chris2017-09-251-4/+4
| | | | | | | | | | * move sql store code into store/sqlstore package * move non-sql constants back up to store * fix api test * derp
* fix plugin test (#7436)Chris2017-09-121-1/+2
| | | | | | | | | | | | * fix plugin test * ugh. global state * Fix plugin test * Fix TestDeleteChannel * Remove plugin config listener when shutting down
* Renaming repoChristopher Speller2017-09-061-3/+3
|
* app type transition (#7167)Chris2017-09-061-35/+34
|
* PLT-3893: Structured Logging Continues (#7252)Jonathan2017-08-311-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PLT-3893: Imported logger work from https://github.com/MusikPolice/platform * PLT-3893: Integrated logger with system config * PLT-3893: Integrated Mattermost config with logging solution, modified log message serialization so entire message is serialized as a JSON object * PLT-3893: Added support for format strings in Debug methods. Added an overload that does not require a Context object for cases when one isn't available * PLT-3893: Added context and format string support to debug and error methods * PLT-3893: A few updates from pull request feedback * PLT-3893: Changed tests to use testify * Fixed TestAddRemoveConfigListener to no longer assume that there are zero config listeners when the test begins, since other tests could add config listeners * Updated TestGetDeletedChannelsForTeam so that it doesn't assume state when it begins * PLT-3893: Changed File property of log message so that it's relative to /mattermost directory, rather than to wherever the user is running the application from on their machine * Flipped expected/actual assert arguments, added an explicit test for getCallerFilename(...), since it's failing on Jenkins * Added printlns to debug failing tests on Jenkins * Relaxed test cases to avoid failure on Jenkins caused by code coverage calculations. Removed printlns. * Changed the way that caller filename is determined to make it more robust, updated tests to make them more lax, while not choking on the strange paths that Jenkins uses. * Fixed gofmt issues * Added debug output to tests to diagnose Jenkins build failures * Still trying to get some useful debug logging on Jenkins * Changed getCallerFilename to handle the strange paths that runtime.Caller(...) returns on Jenkins * Fixing checkstyle issues
* PLT-6226 Fixing races with licensing (#7213)Corey Hulen2017-08-161-72/+72
| | | | | | | | | | * PLT-6226 Fixing races with licensing * Fixing build issue * Fixing licensing issue * removing commented code
* PLT-7206: Remove the "Delete Channel" option for private channels if you're ↵Jonathan2017-08-091-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | the last channel member and policy setting restricts channel deletion (#7050) * PLT-7206: UI changes. Removed last user in channel loophole, refactored code to clean it up, added differentiated support for public and private channels, added unit tests. Still need to implement server-side checks * PLT-7206: All helper methods in channel_utils.jsx now accept the same three boolean variables in the same order and use the same boolean logic to check their values. * PLT-7206: Added unit tests for showManagementOptions(...) * PLT-7206: Fixed test case descriptions * Added unit tests for showCreateOption(...) * PLT-7206: Added unit tests for canManageMembers(...) * PLT-7206: Removed last person in channel loophole from server-side code * PLT-7206: Reverted config.json * PLT-7206: Fixed double negatives in unit test names * PLT-7206: PR feedback - Removed confusing comment and unused variable
* [PLT-6838] Restrict channel delete option per permission policy even for ↵Saturnino Abril2017-07-051-3/+11
| | | | | | | | | | last channel member (#6706) * channel delete option is hidden from the menu unless there is appropriate permissions as set in the policy page * apply to public channel only and add restriction to API layer * updated channel deletion
* Move remaining actions over to use redux and v4 endpoints (#6720)Joram Wilander2017-06-261-2/+2
|
* PLT-6019: Add APIv4 Endpoint for restoring Channels (#6263)Robin Naundorf2017-05-151-0/+26
|
* Merge branch 'release-3.9' into merge-3.9JoramWilander2017-05-121-0/+10
|\
| * PLT-6556 Fixed last member of a channel not being able to delete channel ↵Harrison Healey2017-05-111-0/+10
| | | | | | | | with api v4 (#6397)
* | Removing channel list alias from apiv4 client (#6383)Christopher Speller2017-05-101-19/+19
| |
* | Add API Endpoint for deleted Channels (#5889)Robin Naundorf2017-05-091-0/+49
|/
* PLT-6214 Move channel store and actions over to redux (#6235)Joram Wilander2017-04-281-1/+1
| | | | | | | | | | | | | | * Move channel store and actions over to redux * Fix style errors * Fix unit test * Various fixes * More fixes * Revert config changes
* APIv4 POST /channels/group (#6166)Saturnino Abril2017-04-201-0/+73
|
* PLT-5860 Updated copyright date (#6058)Harrison Healey2017-04-121-1/+1
| | | | | | | | | | | | * PLT-5860 Updated copyright date in about modal * PLT-5860 Updated copyright notice in JSX files * PLT-5860 Updated copyright notice in go files * Fixed misc copyright dates * Fixed component snapshots
* PLT-4858: Unit tests to cover this bug. (#5990)George Goldberg2017-04-051-0/+24
|
* PLT-5900 Removed automatic configuration of SiteURL (#5952)Harrison Healey2017-04-041-1/+1
| | | | | | | | | | | | | | | | * Revert "PLT-5765 Passed SiteURL to SendNotifications (#5705)" This reverts commit a8e68bd8905972ae59de90fa33d5b3e3c274dc47. * Removed automatic configuration of SiteURL * Reverted unintentional config changes * Updated help text * Added link to docs in Site URL warning * Fixed merge conflict
* PLT-6139 (Server): Private Channel member managing (#5941)George Goldberg2017-04-031-0/+248
| | | | Adds an EE policy feature to allow restricting system-wide which level of Admins can manage the membership of private channels.
* Use 201 status code where appropriate for APIv4 (#5903)Joram Wilander2017-03-311-0/+2
|
* Implement PUT /channels/{channel_id}/members/{user_id}/notify_props for ↵Joram Wilander2017-03-311-0/+50
| | | | APIv4 (#5901)
* APIv4 get /channels/{channel_id}/pinned (#5893)Saturnino Abril2017-03-291-0/+39
|
* APIv4 post /channels/ids (#5845)Saturnino Abril2017-03-271-0/+63
| | | | | | * APIv4 post /channels/ids * updated enpoint as /teams/{team_id}/channels/ids
* Implement some channel endpoints for APIv4 (#5846)Joram Wilander2017-03-241-0/+159
| | | | | | | | | | * Add v4 endpoint for getting the channels on a team for a user * Implement PUT /channels/{channel_id}/patch endpoint for APIv4 * Implement POST /teams/{team_id}/channels/search endpoint for APIv4 * Update permission check
* Fix delete channel test (#5863)Joram Wilander2017-03-231-0/+12
|
* Merge branch 'release-3.7'George Goldberg2017-03-231-1/+14
|\
| * Fxing some unit testsChristopher Speller2017-03-221-1/+1
| |
| * Fix policy application in team edition. (#5771)George Goldberg2017-03-151-1/+14
| |
* | Update channel permissions for v4 endpoints (#5829)Joram Wilander2017-03-221-3/+50
| | | | | | | | | | | | | | | | * Fix join channel permission for v4 endpoint * Allow regular users to get public channels they are not in * Fix unit test
* | Fxing some unit tests (#5817)Christopher Speller2017-03-201-1/+1
| |
* | Endpoint for APIv4 POST /channels/{channel_id}/members (#5775)Saturnino Abril2017-03-201-0/+88
| |
* | Merge branch 'release-3.7' into master.George Goldberg2017-03-171-1/+1
|\|
* | Implement some channel endpoints for APIv4 (#5767)Joram Wilander2017-03-161-0/+125
| |
* | APIv4 DELETE channels/{channel_id} (#5723)Saturnino Abril2017-03-141-0/+239
| |
* | add update channel endpoint for APIv4 (#5624)Carlos Tadeu Panato Junior2017-03-131-0/+72
| |
* | Endpoint for APIv4: GET /team/{team_id}/channels (#5681)Saturnino Abril2017-03-131-0/+80
|/
* Fix JS error when receiving reply during channel switch (#5582)Joram Wilander2017-03-031-0/+11
|
* Implement a few channel member endpoints for APIv4 (#5444)Joram Wilander2017-02-201-3/+196
| | | | | | | | * Implement POST /channels/members/{user_id}/view endpoint for APIv4 * Implement PUT /channels/{channel_id}/members/{user_id}/roles endpoint for APIv4 * Implement DELETE /channels/{channel_id}/members/{user_id} endpoint for APIv4
* Implement GET channels endpoints for APIv4 (#5363)Ruzette Tanyag2017-02-141-1/+79
| | | | | | | | | | | | * implement get channels endpoints and updated drivers and unittests * removed channel deletion on tear down, removed manage permission on get channels endpoints, and updated utils to add constant channel length * added constants for user, team and channel length, updated context to use the model functions * make sure team name length should be less than the minimum length and revert underscore to team name validity * changed post test condition from notfound to unauthorized
* Implement some post endpoints for APIv4 (#5353)Joram Wilander2017-02-131-2/+2
| | | | | | | | | | | | * Implement POST /posts endpoint for APIv4 * Implement GET /channels/{channel_id}/posts endpoint for APIv4 * Implement GET /posts/{post_id} endpoint for APIv4 * Implement GET /posts/{post_id}/thread endpoint for APIv4 * Skip team get if it's a DM channel in handlePostEvents