Commit Graph

19025 Commits

Author SHA1 Message Date
Steve Howell
1ef9b7982e Set threshold to 0.03% for code coverage.
We want a little bit of wiggle room for code coverage.
Some legitimate commits that remove code from the system
appear to reduce overall code coverage.
2017-07-05 15:07:52 -07:00
Steve Howell
1327031628 Remove patch section from .codecov.yml.
The `patch` option for code coverage only reports on lines that
are part of the patch, which tends to be misleading for things
like refactoring commits that may actually increase overall
code coverage for the project.
2017-07-05 15:07:52 -07:00
Cory Lynch
099a7052e4 Enforce 100% test coverage for stream_events.js. 2017-07-05 17:57:52 -04:00
Cory Lynch
43544cef28 stream_events: Add tests for mark_unsubscribed. 2017-07-05 17:57:52 -04:00
Cory Lynch
2627c1cde3 stream_events: Add tests for mark_subscribed. 2017-07-05 17:57:52 -04:00
Cory Lynch
c8281de492 stream_events: Add tests for update_property. 2017-07-05 17:57:52 -04:00
Harshit Bansal
efc2df168c subs: Fix the autocomplete suggestions while adding subscribers.
Earlier, the autocomplete was also showing the emails of the users who
were already subscribed to the stream.

Fixes: #4028.
2017-07-05 13:22:07 -07:00
Harshit Bansal
598535717b emoji_picker: Extract add_scrollbar() function.
Calling this function with  an element will cause a `perfectScrollbar` to
be added to it.
2017-07-05 13:14:40 -07:00
Harshit Bansal
a6cd460f72 emoji: Rename emoji.realm_emojis to emoji.all_realm_emojis. 2017-07-05 13:02:41 -07:00
Harshit Bansal
29ff36cd2a reactions: Don't send add/remove requests for deactivated realm emojis.
Eventually, we'll want to support unreacting to deactivated realm
emoji, but for now the issues around name conflicts mean we can't
really support that.
2017-07-05 13:02:20 -07:00
Harshit Bansal
3c9705ce98 actions.py: Instead of deleting a realm emoji just deactivate it.
Instead of removing an emoji from the database, just mark them as
deactivated so that they can't be used further but can be rendered
properly in reactions and messages.

Fixes: #4750.
2017-07-05 13:00:15 -07:00
Harshit Bansal
c4ec9523fc frontend: Make sure deactivated emojis don't appear for use anywhere.
Deactivated emojis should not appear at any of the following places for
use:
1: Emoji pickers.
2: Composebox autocomplete.
3: Custom emoji settings page.
2017-07-05 13:00:14 -07:00
Harshit Bansal
9e40f063d6 markdown: Use active_realm_emojis instead of realm_emojis.
We should use `active_realm_emojis` instead of manually checking for
deactivated emojis in `realm_emoji` dict.
2017-07-05 12:05:10 -07:00
Harshit Bansal
90f04062e7 emoji.js: Add active_realm_emojis dict.
This dict will hold all the realm emojis which have not been deactivated.
2017-07-05 12:05:10 -07:00
Jack Zhang
13a5c625ca docs: Add note for importing _() function in translating.md. 2017-07-05 12:01:59 -07:00
Jack Zhang
0c50f2ee09 [third] Add lightweight fuzzysearch library.
This is intended to be used in the new /integrations page.
2017-07-05 11:54:55 -07:00
Cynthia Lin
0fc93278ca user docs: Add guide on *Require topics in messages to streams* setting.
Edited by tabbott to simplify the language and explain the purpose of
the setting a bit more.

Fixes #5675.
2017-07-05 11:51:54 -07:00
Vishnu Ks
faf5c0cd2d portico: Make backend validation errors similar to frontend.
The backend errors are currently displayed to the right side of the
input field.  This is different from the frontend validation errors
which are displayed at the bottom of the input field (and also looks
really bad). Also frontend validation uses <p> instead of <div> to
display errors so I have changed this also to make both uniform.
2017-07-05 11:05:18 -07:00
Vaida Plankyte
9461f490c8 event_queue.py: Use the singular 'they' pronoun. 2017-07-05 09:27:44 -07:00
Vaida Plankyte
9b279072df notifications.js: Use the singular 'they' pronoun. 2017-07-05 09:27:44 -07:00
Vaida Plankyte
d8ab716820 german.md: Use the singular 'they' pronoun. 2017-07-05 09:27:44 -07:00
Vaida Plankyte
0352ad517b streams.py: Use the singular 'they' pronoun. 2017-07-05 09:27:44 -07:00
Vaida Plankyte
5aee5b395a message.py: Use the singular 'they' pronoun. 2017-07-05 09:27:44 -07:00
Vaida Plankyte
18bf15cfed git-guide.md: Use the singular 'they' pronoun. 2017-07-05 09:27:44 -07:00
Vaida Plankyte
c88530366e user_settings.py: Use the singular 'they' pronoun. 2017-07-05 09:27:44 -07:00
Vaida Plankyte
43a98b896b custom-apps.md: Use the singular 'they' pronoun. 2017-07-05 09:27:43 -07:00
Vaida Plankyte
8c4ee83980 decorator.py: Use the singular 'they' pronoun. 2017-07-05 09:27:43 -07:00
Vaida Plankyte
5a3d3ae291 narrow.js: Use the singular 'they' pronoun. 2017-07-05 09:27:43 -07:00
Vaida Plankyte
d40f6da7f8 models.py: Use the singular 'they' pronoun. 2017-07-05 09:27:43 -07:00
Vaida Plankyte
0d8720fe0c missed_message.txt: Use the singular 'they' pronoun. 2017-07-05 09:27:43 -07:00
Vaida Plankyte
b68ba0a13e missed_message.html: Use the singular 'they' pronoun. 2017-07-05 11:34:45 +02:00
Vaida Plankyte
c52fc84fd0 bots-guide.md: Use the singular 'they' pronoun. 2017-07-05 11:33:42 +02:00
David Coleman
77dc5df56a uploads: Display year in attachments UI upload timestamp.
Modified timerender.js absolute_time() to include the
year in the returned time stamp string.

Fixes #5600.
2017-07-04 16:13:20 -07:00
Vaida Plankyte
9bb0602ad4 docs: Add info on resolving merge conflicts to git-guide.md.
Fixes #5586.
2017-07-04 15:48:06 -07:00
James Rowan
d88e7308bf emails: Add a FromAddress class to control access to certain settings emails.
No change in behavior.

Also makes the first step towards converting all uses of
settings.ZULIP_ADMINISTRATOR and settings.NOREPLY_EMAIL_ADDRESS to
FromAddress.*.

Once everything is converted, it will be easier to ensure that future
development doesn't break backwards compatibility with the old style of
settings emails.
2017-07-04 14:25:01 -07:00
James Rowan
368bd66d8b emails: Refactor send_email functions to take both a sender name and address.
This will allow for customized senders for emails, e.g. 'Zulip Digest' for
digest emails and 'Zulip Missed Messages' for missed message emails.

Also:
* Converts the sender name to always be "Zulip", if the from_email used to
  be settings.NOREPLY_EMAIL_ADDRESS or settings.ZULIP_ADMINISTRATOR.

* Changes the default value of settings.NOREPLY_EMAIL_ADDRESS in the
  prod_setting_template to no longer have a display name. The only use of
  that display name was in the email pathway.
2017-07-04 14:25:01 -07:00
Rishi Gupta
a8af0b6d91 email_mirror: Change missed message noreply to not have a display name.
It's better to see "noreply@..." when replying to a message that you can't
reply to than "Zulip".
2017-07-04 14:25:01 -07:00
Rishi Gupta
dd3dd26f15 prod_settings_template: Update description for FEEDBACK_EMAIL. 2017-07-04 14:25:01 -07:00
Rishi Gupta
364415bba4 password reset flow: Use default noreply email address. 2017-07-04 14:25:01 -07:00
Tim Abbott
c2ee259987 settings: Simplify testing code for bool realm settings.
Now, when we add a new realm setting with the bool type, we don't need
to edit the tests at all.
2017-07-04 14:23:05 -07:00
Franziska von der Goltz
98847937f4 realm: add mandatory topic setting on org level.
Lets organizations require users to specify a topic the discussion.

Fixes: #5164.
2017-07-04 14:09:21 -07:00
James Rowan
1ea9a23f95 emails: Fix two grammar nits. 2017-07-04 13:57:54 -07:00
Cory Lynch
b13265d135 util: Remove execute_early.
This function was removed in favor of loading everything in
ui_init.js. The asynchronous nature of jQuery 3 document-ready
events may cause an undesirable order in which these are executed.
2017-07-04 13:54:33 -07:00
Cory Lynch
effd7ef41f server_events: Move initialization to ui_init.js. 2017-07-04 13:54:33 -07:00
Cory Lynch
e33b178054 message_store: Move initialization to ui_init.js. 2017-07-04 13:54:33 -07:00
Cory Lynch
25be3a402d message_fetch: Move initialization to ui_init.js.
This involves modifying a casper test, because now
upon registration, there is one unread message.
2017-07-04 13:54:33 -07:00
Tim Abbott
b2ada7e706 docs: Expand documentation on Internet access in tests. 2017-07-04 13:17:25 -07:00
Aditya Bansal
5b81cc2bcd tests: Block internet access to test suites by overriding requests. 2017-07-04 13:17:22 -07:00
Aditya Bansal
26c345f059 backend: Block network access to test suites.
In this commit we basically start to override the request method of
httplib2.Http() to raise an exception whenever it is called i.e.
a trial is made to access the network from test suits.

Fixes: #1472.
2017-07-04 13:17:20 -07:00
Aditya Bansal
caa8a3f7fc Make test_google_oauth2_token_failure() work without internet. 2017-07-04 12:45:27 -07:00