Guo Xiang Tan
636b6c3a5a
FIX: Wrong discobot tutorial started for certain locales.
...
If a locale has triggers that start with the same word, our regexp will
always end up matching the first trigger. For example,
`start tutorial` and `start tutorial advanced`
To support the change, we have to make the match on triggers more
restrictive. `@discobot quote here` will no longer work like `@discobot
quote`.
2019-08-08 10:53:58 +08:00
Guo Xiang Tan
b574276e6e
DEV: Correct hardcoded value in discobot tests.
2019-08-08 10:53:58 +08:00
Guo Xiang Tan
1267185a07
DEV: Remove unused option.
...
Follow up to 18ed03e044
.
2019-07-30 21:12:13 +08:00
Sam Saffron
1efed6e527
DEV: amend test for anonymous handling to use real data
...
Previously we relied on fabrication on anonymous, we can not get the
transaction commit pipeline to work as it does in production, cleanly
This amends it so our anonymous user is created using the core APIs
Signed-off-by: Sam Saffron <sam.saffron@gmail.com>
2019-05-29 15:05:37 +10:00
Sam Saffron
30990006a9
DEV: enable frozen string literal on all files
...
This reduces chances of errors where consumers of strings mutate inputs
and reduces memory usage of the app.
Test suite passes now, but there may be some stuff left, so we will run
a few sites on a branch prior to merging
2019-05-13 09:31:32 +08:00
Guo Xiang Tan
329969ea20
FIX: Discobot mention tutorial should be case insensitive.
2019-05-07 10:54:22 +08:00
Tim Lange
d5d784b9f2
FIX: Narration Bot now gets site setting for automatic post deletion ( #7432 )
2019-04-25 07:29:20 +08:00
Robin Ward
b58867b6e9
FEATURE: New 'Reviewable' model to make reviewable items generic
...
Includes support for flags, reviewable users and queued posts, with REST API
backwards compatibility.
Co-Authored-By: romanrizzi <romanalejandro@gmail.com>
Co-Authored-By: jjaffeux <j.jaffeux@gmail.com>
2019-03-28 12:45:10 -04:00
Penar Musaraj
9334d2f4f7
FEATURE: add more granular user option levels for email notifications ( #7143 )
...
Migrates email user options to a new data structure, where `email_always`, `email_direct` and `email_private_messages` are replace by
* `email_messages_level`, with options: `always`, `only_when_away` and `never` (defaults to `always`)
* `email_level`, with options: `always`, `only_when_away` and `never` (defaults to `only_when_away`)
2019-03-15 10:55:11 -04:00
Robin Ward
fa5a158683
REFACTOR: Move `queue_jobs` out of `SiteSetting`
...
It is not a setting, and only relevant in specs. The new API is:
```
Jobs.run_later! # jobs will be thrown on the queue
Jobs.run_immediately! # jobs will run right away, avoid the queue
```
2019-03-14 10:47:38 -04:00
Guo Xiang Tan
b0c8fdd7da
FIX: Properly support defaults for upload site settings.
2019-03-13 16:36:57 +08:00
Robin Ward
d1d9a4f128
Add new `run_jobs_synchronously!` helper for tests
...
Previously if you wanted to have jobs execute in test mode, you'd have
to do `SiteSetting.queue_jobs = false`, because the opposite of queue
is to execute.
I found this very confusing, so I created a test helper called
`run_jobs_synchronously!` which is much more clear about what it does.
2019-03-11 16:58:35 -04:00
Penar Musaraj
3c5fbd3ce1
FIX: do not send welcome message to staged users
2019-01-30 18:03:16 -05:00
Guo Xiang Tan
6fde58ff90
FIX: Make Discobot image tutorial accept URL that points to images.
2018-11-15 10:52:18 +08:00
Guo Xiang Tan
44391ee8ab
FEATURE: Upload Site Settings. ( #6573 )
2018-11-14 15:03:02 +08:00
Gerhard Schlager
24e5be3f0c
FIX: Relative links in translations should work with subfolder
2018-11-08 23:31:05 +00:00
Neil Lalonde
a530606da7
fix narrative bot spec to include base_uri key in translations
2018-09-21 12:37:35 -04:00
Guo Xiang Tan
c1c9637b39
Skip Discobot flag tutorial if `allow_flagging_staff` is disabled.
...
https://meta.discourse.org/t/interacting-with-discobot/96574
2018-09-07 08:33:27 +08:00
Guo Xiang Tan
ff0979553d
Skip discobot mention tutorial if mentions are disabled.
2018-08-23 14:58:07 +08:00
Guo Xiang Tan
07d07c7b5f
FIX: Make Discobot certificate route require login.
2018-08-20 11:22:59 +08:00
Guo Xiang Tan
49f39ca64d
Fix another failing spec.
2018-06-07 15:07:39 +08:00
Guo Xiang Tan
610510ebad
Fix broken discourse narrative bot spec after upgrade.
2018-06-07 15:03:09 +08:00
Sam
e806e6e96f
correct specs
2018-06-07 16:13:15 +10:00
Guo Xiang Tan
7fc8a36529
DEV: Take 2 Queue jobs in tests by default.
...
On my machine this cuts the time taken to run our test suite
from ~11mins to ~9mins.
2018-05-31 16:23:23 +08:00
Guo Xiang Tan
56e9ff6853
Revert "DEV: Queue jobs in tests by default."
...
Too risky for now
This reverts commit be28154d3b
.
2018-05-31 15:34:46 +08:00
Guo Xiang Tan
be28154d3b
DEV: Queue jobs in tests by default.
2018-05-31 14:45:47 +08:00
Guo Xiang Tan
9f873fa66c
FIX: Invalid setex expire time in `DiscourseNarrativeBot::Actions#reset_rate_limits`.
2018-05-25 16:02:15 +08:00
Michael Brown
ed4d7ae1b9
FIX: discobot fails when max_emojis_in_title=0 ( #5710 )
...
* If discobot is enabled but max_emojis_in_title==0,
try to strip emoji from the title when creating a new post
2018-03-27 18:00:29 +02:00
Sam
7e3543d96f
correct plugin specs
2018-01-12 14:42:05 +11:00
Guo Xiang Tan
d80aca0484
FIX: Don't start discobot poll tutorial if polls are disabled.
...
https://meta.discourse.org/t/discobot-dont-take-users-through-the-poll-tutorial-if-its-not-enabled/76604/3
2017-12-22 15:46:46 +08:00
Guo Xiang Tan
32171ad286
FIX: Invalid logo in discobot's certificate when `SiteSetting.logo_small_url` is blank.
...
https://meta.discourse.org/t/broken-image-in-discobot-certificate-with-no-logo-small-url/76594/2
2017-12-22 09:36:53 +08:00
Guo Xiang Tan
ee1b90503c
FIX: Error when an invalid date is passed to certificate generator.
...
https://meta.discourse.org/t/broken-image-in-discobot-certificate-with-no-logo-small-url/76594/2
2017-12-22 09:36:52 +08:00
Guo Xiang Tan
442d4bff85
Add onceoff job to remap bot images link.
...
https://meta.discourse.org/t/discobot-tutorial-broken-elipsis-and-bookmark-png-images-appear-to-be-missing-on-my-site/73294/12
2017-11-07 23:36:59 +08:00
Guo Xiang Tan
6cb29e3e20
Remove custom symlinks in discourse-narrative-bot.
2017-10-10 13:46:58 +08:00
Guo Xiang Tan
77d4c4d8dc
Fix all the errors to get our tests green on Rails 5.1.
2017-09-25 13:48:58 +08:00
Guo Xiang Tan
950fa9e3a8
FIX: Skip trigger match should be case insensitive.
...
https://meta.discourse.org/t/discobot-not-skipping-tutorial/68498
2017-08-22 07:45:46 +09:00
Guo Xiang Tan
5012d46cbd
Add rubocop to our build. ( #5004 )
2017-07-28 10:20:09 +09:00
Sam
14c2439473
correct specs so they run on latest
2017-07-18 15:45:23 -04:00
Guo Xiang Tan
c049e18203
FEATURE: Allow tutorials to declare prerequisite before it starts.
2017-07-13 15:12:45 +09:00
Robin Ward
f1a6449e4b
SECURITY: Remove disposable invite feature
2017-07-07 20:24:39 -04:00
Guo Xiang Tan
f8a46c510f
FIX: Recover post tutorial does not work when `SiteSetting.delete_removed_posts_after` is 0.
2017-06-16 13:03:34 +09:00
Guo Xiang Tan
e888369f51
UX: Don't send emails for discobot notifications.
2017-06-12 17:00:27 +09:00
Guo Xiang Tan
977bbb1f45
FIX: Bot mentioned check should be case insensitive.
2017-06-08 19:00:07 +09:00
Guo Xiang Tan
677fbc783d
Fix randomly failing spec.
2017-06-08 05:47:44 +09:00
Guo Xiang Tan
c1dc6f6cd7
FIX: Track should only continue if user is alone with bot in a PM.
2017-06-06 09:47:00 +09:00
Guo Xiang Tan
30f2758404
FIX: Ensure that we cancel any timeout jobs when terminating a track.
2017-06-05 16:23:25 +09:00
Guo Xiang Tan
3621647fb5
FIX: Bot should only respond to regular posts.
2017-06-05 15:21:19 +09:00
Neil Lalonde
23dfddbfb4
FIX: narrative bot on subfolder installs
2017-06-01 15:15:34 -04:00
Guo Xiang Tan
edbb876d1b
FIX: Discobot welcome post delay should start counting when a user logs in.
2017-06-01 21:02:29 +09:00
Guo Xiang Tan
4144ea34a2
Rename a test file.
2017-05-31 06:38:38 +09:00
Guo Xiang Tan
56f98de7b2
Use webmock to stub external web requests.
2017-05-26 15:19:09 +08:00
Guo Xiang Tan
144b810d0e
Missed a spot when redefining a method.
2017-05-26 13:02:41 +08:00
Guo Xiang Tan
18dac4ce9f
UX: Remove restrictions on advanced user track.
2017-05-26 11:05:09 +08:00
Guo Xiang Tan
7028bdceed
FIX: Allow users to rename discobot without having to rebuild.
2017-05-26 10:09:42 +08:00
Guo Xiang Tan
ee23ce5acc
FIX: Allow advanced tutorial to be started if badges are disabled.
2017-05-24 18:34:10 +08:00
Guo Xiang Tan
7f0561b621
Merge discourse-narrative-bot into core plugins.
2017-05-24 15:28:34 +08:00