Repository: s/preprocessor (language: python)

Issue:
"reserved_words" not working
**The bug**
Reserved word not working

**To Reproduce**
Steps to reproduce the behavior:
```
import preprocessor as p

parse_text = p.parse("@RT @name Preprocessor is #awesome 👍 https://github.com/s/preprocessor https://www.google.com ")
print(parse_text.reserved_words)

# output None
```

**Expected behavior**
```parse_text.reserved_words``` should return ```RT```  because it is a reserved word or am I doing anything wrong here?

How can I get reserved words from this tweet?
Is there a method to parse the reserved words if the above method is not applicable?

**Desktop**
 - OS: [Windows]
 - Python Version: [3.6+] 
 - preprocessor version [0.6.0]


"reserved_words" not working
**The bug**
Reserved word not working

**To Reproduce**
Steps to reproduce the behavior:
```
import preprocessor as p

parse_text = p.parse("@RT @name Preprocessor is #awesome 👍 https://github.com/s/preprocessor https://www.google.com ")
print(parse_text.reserved_words)

# output None
```

**Expected behavior**
```parse_text.reserved_words``` should return ```RT```  because it is a reserved word or am I doing anything wrong here?

How can I get reserved words from this tweet?
Is there a method to parse the reserved words if the above method is not applicable?

**Desktop**
 - OS: [Windows]
 - Python Version: [3.6+] 
 - preprocessor version [0.6.0]




Discussion / hints:

Fix patch:
diff --git a/preprocessor/defines.py b/preprocessor/defines.py
index f7eed0d..fa74c38 100644
--- a/preprocessor/defines.py
+++ b/preprocessor/defines.py
@@ -58,7 +58,7 @@ class Patterns:
     URL_PATTERN = re.compile(URL_PATTERN_STR, re.IGNORECASE)
     HASHTAG_PATTERN = re.compile(r'#\w*')
     MENTION_PATTERN = re.compile(r'@\w*')
-    RESERVED_WORDS_PATTERN = re.compile(r'^(RT|FAV)')
+    RESERVED_WORDS_PATTERN = re.compile(r'\b(?<![@#])(RT|FAV)\b')
 
     try:
         # UCS-4


Test patch:
diff --git a/tests/test_api.py b/tests/test_api.py
index 803a76c..43c8786 100755
--- a/tests/test_api.py
+++ b/tests/test_api.py
@@ -47,6 +47,12 @@ def test_clean_smileys(self):
         cleaned_tweet = p.clean(tweet)
         self.assertEqual('expression experience zoxo xoyo', cleaned_tweet)
 
+    def test_clean_reserved_words(self):
+        tweet = "Awesome!!! RT @RT: This is a tweet about art ART. FAV #RT #FAV #hashtag"
+        p.set_options(p.OPT.RESERVED)
+        cleaned_tweet = p.clean(tweet)
+        self.assertEqual('Awesome!!! @RT: This is a tweet about art ART. #RT #FAV #hashtag', cleaned_tweet)
+
     def test_tokenize(self):
         tweet = 'Packathon was a really #nice :) challenging 👌. @packathonorg http://packathon.org'
         p.set_options(p.OPT.URL, p.OPT.HASHTAG, p.OPT.MENTION, p.OPT.EMOJI, p.OPT.SMILEY)