瀏覽代碼

Fix fixtures

theenglishway (time) 7 年之前
父節點
當前提交
b7acdd3d5a

+ 22 - 12
tests/fixtures/tweets/link_10.yaml

@@ -1,15 +1,17 @@
 - !!python/object:twhatter.parser.user.User
   followers_nb: 10
   following_nb: 30
+  fullname: theenglishway
   id: 943804775942033408
   join_date: 2017-12-21 00:00:00
   likes_nb: 17
-  screen_name: theenglishway
+  username: the_english_way
   soup: null
   tweets_nb: 83
 
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: [GrandDebat]
   id: 1087059470621048836
   likes_nb: 0
@@ -22,7 +24,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Vu dans le dernier @canardenchaine, le remplacement dans 2 r\xE9gions de\
     \ l'enqu\xEAte publique pour les projets environnementaux par une consultation\
@@ -33,6 +35,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: [blog, AffaireBenalla]
   id: 1085843193885851648
   likes_nb: 1
@@ -45,7 +48,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 2
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Nouvel article sur mon #blog : un r\xE9sum\xE9 qui se veut objectif des auditions\
     \ d'hier dans l'#AffaireBenalla (mais n'y parvient pas). Et un grand merci au\
@@ -55,6 +58,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 2
+  fullname: theenglishway
   hashtag_list: []
   id: 1077505613079429120
   likes_nb: 1
@@ -67,7 +71,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 1
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Le p\xE8re No\xEBl, un bon exemple de socialisme compar\xE9 \xE0 la petite\
     \ souris ou \xE0 Halloween ? :Dhttps://jacobinmag.com/2018/12/santa-claus-socialism-christmas\_\
@@ -76,6 +80,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: [blog]
   id: 1060480082987356161
   likes_nb: 0
@@ -88,7 +93,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Nouvel article sur mon #blog :https://blog.theenglishway.eu/la-gratuite.html#la-gratuite\_\
     \u2026"
@@ -96,6 +101,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: []
   id: 1052565222316285957
   likes_nb: 0
@@ -108,7 +114,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Journal de bord, entr\xE9e #1 : http://blog.theenglishway.eu/log-001.html\_\
     \n(ou aussi : @CCI_Paris_IdF c'est bien!)"
@@ -116,6 +122,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: [blog]
   id: 1037399737480212480
   likes_nb: 0
@@ -128,7 +135,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Nouvel article sur mon #blog ! \nComment faire un business model qui claque,\
     \ selon Wall Street, ou \"qu'est ce qui fait la valeur d'une boite selon les investisseurs\"\
@@ -138,6 +145,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: [blog, functionalstupidity]
   id: 1036172843065790466
   likes_nb: 0
@@ -150,7 +158,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "New article on my #blog : functional stupidity, or how our work-places drive\
     \ us into stupidity (introducing Mats Alvesson and @andre_spicer 's book on #functionalstupidity)http://blog.theenglishway.eu/en/functional-stupidity-0.html\_\
@@ -159,6 +167,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: [blog]
   id: 1036172317443989505
   likes_nb: 1
@@ -171,7 +180,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Nouvel article sur mon #blog : la stupidit\xE9 fonctionelle, ou comment nos\
     \ environnements de travail nous poussent \xE0 la stupidit\xE9 (introduction au\
@@ -181,6 +190,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: []
   id: 1028882171816275968
   likes_nb: 0
@@ -193,7 +203,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "Article miniature sur Alan Turing :http://blog.theenglishway.eu/alan-turing.html\_\
     \u2026"
@@ -201,6 +211,7 @@
   user_id: 943804775942033408
 - !!python/object:twhatter.parser.tweet.TweetLink
   comments_nb: 0
+  fullname: theenglishway
   hashtag_list: [blog]
   id: 1027798020174372865
   likes_nb: 0
@@ -213,10 +224,9 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 0
-  screen_name: the_english_way
+  username: the_english_way
   soup: null
   text: "And now for something completely different ! First dive into @sqlalchemy\
     \ #bloghttp://blog.theenglishway.eu/en/sqlalchemy-intro.html\_\u2026"
   timestamp: 2018-08-10 06:05:18
   user_id: 943804775942033408
-

+ 18 - 9
tests/fixtures/tweets/reaction_9.yaml

@@ -1,5 +1,6 @@
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 350
+  fullname: David Dufresne
   hashtag_list: [ActeX]
   id: 1086603899186880512
   likes_nb: 3413
@@ -12,7 +13,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 2348
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "La fatigue nerveuse, la pression, le renversement m\xE9diatique soudain,\
     \ le d\xE9ni politique qui s'acharne, et puis les larmes. \n\nEt aujourd'hui,\
@@ -23,6 +24,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 111
+  fullname: David Dufresne
   hashtag_list: []
   id: 1087111932560244736
   likes_nb: 1006
@@ -35,7 +37,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 582
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "\xABOn ne peut pas demander aux manifestants d'\xEAtre exemplaires si on\
     \ ne l'est pas soi-m\xEAme \xBB, a estim\xE9 dimanche le porte-parole du gouvernement,\
@@ -46,6 +48,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 16
+  fullname: David Dufresne
   hashtag_list: []
   id: 1087053227227578369
   likes_nb: 217
@@ -58,7 +61,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 201
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "Rectificatif: les images sont sign\xE9es @ClementLanot (dont le travail est\
     \ remarquable)  https://www.youtube.com/watch?v=fDugakictUw\_\u2026 ( \xE0 27mn11s)https://twitter.com/davduf/status/1087043032350973958\_\
@@ -67,6 +70,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 39
+  fullname: David Dufresne
   hashtag_list: []
   id: 1086946146398945281
   likes_nb: 332
@@ -79,7 +83,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 100
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "Les commentaires sur le fil Twitter de @LEXPRESS sont charmants comme un\
     \ dimanche matin.https://twitter.com/LEXPRESS/status/1086879785530331141\_\u2026"
@@ -87,6 +91,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 3
+  fullname: David Dufresne
   hashtag_list: [ActeX, Montepellier, LBD40]
   id: 1086779719599747072
   likes_nb: 103
@@ -99,7 +104,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 158
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "allo @Place_Beauvau - c'est pour un signalement - 325 (pr\xE9cisions)\n\n\
     #ActeX #Montepellier #LBD40https://twitter.com/OctavieMrl/status/1086770685471531008\_\
@@ -108,6 +113,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 5
+  fullname: David Dufresne
   hashtag_list: [ActeX, Montepellier, LBD40]
   id: 1086779578918584321
   likes_nb: 153
@@ -120,7 +126,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 264
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "allo @Place_Beauvau - c'est pour un signalement - 326 (pr\xE9cisions)\n\n\
     #ActeX #Montepellier #LBD40https://twitter.com/OctavieMrl/status/1086774517647790080\_\
@@ -129,6 +135,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 7
+  fullname: David Dufresne
   hashtag_list: [LBD40, Montepellier, ActeX]
   id: 1086707919138234369
   likes_nb: 154
@@ -141,7 +148,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 264
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "allo @Place_Beauvau - c'est pour un signalement - 331\n\nTir de #LBD40 dans\
     \ les fesses\n\n#Montepellier, #ActeXhttps://twitter.com/OctavieMrl/status/1086692368835923969\_\
@@ -150,6 +157,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 38
+  fullname: David Dufresne
   hashtag_list: [Rennes, ActeX]
   id: 1086689891851882496
   likes_nb: 840
@@ -162,7 +170,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 1094
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "allo @Place_Beauvau - c'est pour un signalement - 329\n\nGaz lacrymog\xE8\
     nes malgr\xE9 un passant au sol. Malaise cardiaque. \n\nNon assistance \xE0 personne\
@@ -172,6 +180,7 @@
   user_id: 12786782
 - !!python/object:twhatter.parser.tweet.TweetReaction
   comments_nb: 6
+  fullname: David Dufresne
   hashtag_list: [LBD40, ActeX]
   id: 1086672423553064961
   likes_nb: 204
@@ -184,7 +193,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 343
-  screen_name: davduf
+  username: davduf
   soup: null
   text: "allo @Place_Beauvau - c'est pour un signalement - 327\n\n#LBD40, jambe droite\
     \ sur vid\xE9aste\n\nParis, #ActeXhttps://twitter.com/Le_Figaro/status/1086666326981201920\_\

+ 20 - 10
tests/fixtures/tweets/retweet_10.yaml

@@ -1,5 +1,6 @@
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 724
+  fullname: Twitter Movies
   hashtag_list: [FilmTwitter]
   id: 1072503598372638720
   likes_nb: 4089
@@ -12,7 +13,7 @@
   retweet_id: 1072583629258309632
   retweeter: Twitter
   retweets_nb: 802
-  screen_name: TwitterMovies
+  username: TwitterMovies
   soup: null
   text: "#FilmTwitter, you get to decide what the ultimate holiday movie is.\n \n\
     12/11  Round 1 \n12/12  Semi-Final \n12/13  Final\n12/14  Winner Crowned \n\n\
@@ -21,6 +22,7 @@
   user_id: 436266454
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 2474
+  fullname: Twitter Music
   hashtag_list: [ThisHappened]
   id: 1070274641594327041
   likes_nb: 534808
@@ -33,7 +35,7 @@
   retweet_id: 1070337144504365057
   retweeter: Twitter
   retweets_nb: 182492
-  screen_name: TwitterMusic
+  username: TwitterMusic
   soup: null
   text: "You did it ARMY. @BTS_twt was the most Tweeted about in 2018. \n\nMore music\
     \ facts in the thread below. Yep, #ThisHappenedhttps://twitter.com/TwitterData/status/1070272742849687553\_\
@@ -42,6 +44,7 @@
   user_id: 373471064
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 727
+  fullname: Stephen King
   hashtag_list: []
   id: 986643494499438592
   likes_nb: 35480
@@ -54,13 +57,14 @@
   retweet_id: 1063100430719180802
   retweeter: Twitter
   retweets_nb: 7095
-  screen_name: StephenKing
+  username: StephenKing
   soup: null
   text: Graffiti is the Twitter of the streets.
   timestamp: 2018-04-18 16:31:54
   user_id: 2233154425
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 127
+  fullname: Holly Brockwell
   hashtag_list: []
   id: 1060331216434577409
   likes_nb: 12788
@@ -73,7 +77,7 @@
   retweet_id: 1060694382020452352
   retweeter: Twitter
   retweets_nb: 3577
-  screen_name: holly
+  username: holly
   soup: null
   text: 'There are two social networks: Twitter, and all the ones that post screenshots
     of posts from Twitter'
@@ -81,6 +85,7 @@
   user_id: 7555262
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 141
+  fullname: Twitter India
   hashtag_list: [HappyDeepavali]
   id: 1060087039369068544
   likes_nb: 2744
@@ -93,7 +98,7 @@
   retweet_id: 1060202167657742336
   retweeter: Twitter
   retweets_nb: 368
-  screen_name: TwitterIndia
+  username: TwitterIndia
   soup: null
   text: 'We wish everyone who''s celebrating the festival of lights a very #HappyDeepavali
     May you and your family have a wonderful year ahead!'
@@ -101,6 +106,7 @@
   user_id: 103770785
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 265
+  fullname: Twitter Government
   hashtag_list: [BeAVoter]
   id: 1058023358032371712
   likes_nb: 1950
@@ -113,7 +119,7 @@
   retweet_id: 1058094152062304257
   retweeter: Twitter
   retweets_nb: 573
-  screen_name: TwitterGov
+  username: TwitterGov
   soup: null
   text: 'Election Day in the US is right around the corner. Everyone, including these
     people you may know, wants you to show up to the polls.
@@ -124,6 +130,7 @@
   user_id: 222953824
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 320
+  fullname: underdog
   hashtag_list: []
   id: 1057860310143508480
   likes_nb: 39435
@@ -136,13 +143,14 @@
   retweet_id: 1058014225585631233
   retweeter: Twitter
   retweets_nb: 8779
-  screen_name: lilyachty
+  username: lilyachty
   soup: null
   text: Yo twitter just might be the best place of all time
   timestamp: 2018-11-01 05:02:06
   user_id: 175198393
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 1795
+  fullname: Twitter Safety
   hashtag_list: []
   id: 1057675174735155200
   likes_nb: 15065
@@ -155,7 +163,7 @@
   retweet_id: 1057678634004217856
   retweeter: Twitter
   retweets_nb: 3710
-  screen_name: TwitterSafety
+  username: TwitterSafety
   soup: null
   text: "Activity that attempts to manipulate or disrupt Twitter\u2019s service is\
     \ not allowed. We remove this when we see it.\n\nYou can now specify what type\
@@ -164,6 +172,7 @@
   user_id: 95731075
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 125
+  fullname: Twitter Data
   hashtag_list: []
   id: 1057290498203926528
   likes_nb: 2438
@@ -178,7 +187,7 @@
   retweet_id: 1057363608764592133
   retweeter: Twitter
   retweets_nb: 579
-  screen_name: TwitterData
+  username: TwitterData
   soup: null
   text: "r u abbreving less rn? \n\nSince the switch to 280 characters a year ago,\
     \ we've seen an increase in people writing out full words and phrases.pic.twitter.com/pjnfyVmilY"
@@ -186,6 +195,7 @@
   user_id: 1526228120
 - !!python/object:twhatter.parser.tweet.TweetRetweet
   comments_nb: 4656
+  fullname: Ariana Grande
   hashtag_list: []
   id: 1055221967048060928
   likes_nb: 138890
@@ -198,7 +208,7 @@
   retweet_id: 1055232863933612033
   retweeter: Twitter
   retweets_nb: 21301
-  screen_name: ArianaGrande
+  username: ArianaGrande
   soup: null
   text: i love retweeting my own tweets
   timestamp: 2018-10-24 22:18:16

+ 22 - 11
tests/fixtures/tweets/text_only_10.yaml

@@ -1,15 +1,17 @@
 - !!python/object:twhatter.parser.user.User
   followers_nb: 55903189
   following_nb: 140
+  fullname: Twitter
   id: 783214
   join_date: 2007-02-20 00:00:00
   likes_nb: 5590
-  screen_name: Twitter
+  username: Twitter
   soup: null
   tweets_nb: 8706
 
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 970
+  fullname: Twitter
   hashtag_list: []
   id: 1087225139538862080
   likes_nb: 16305
@@ -22,13 +24,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 2423
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: ''
   timestamp: 2019-01-21 05:47:27
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 3446
+  fullname: Twitter
   hashtag_list: []
   id: 1087059835370328064
   likes_nb: 52960
@@ -41,13 +44,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 7850
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: Tweeting...
   timestamp: 2019-01-20 18:50:36
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 1269
+  fullname: Twitter
   hashtag_list: []
   id: 1086379213349769216
   likes_nb: 34958
@@ -60,13 +64,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 6117
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: Weekends spark joy
   timestamp: 2019-01-18 21:46:03
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 15775
+  fullname: Twitter
   hashtag_list: []
   id: 1085915351605424128
   likes_nb: 49578
@@ -79,13 +84,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 4849
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: You. In emojis.
   timestamp: 2019-01-17 15:02:49
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 3352
+  fullname: Twitter
   hashtag_list: [TriggersMeIn4Words]
   id: 1085718564286345217
   likes_nb: 39887
@@ -98,13 +104,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 7958
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: 'Your edit button requests #TriggersMeIn4Words'
   timestamp: 2019-01-17 02:00:52
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 3502
+  fullname: Twitter
   hashtag_list: []
   id: 1085569366358257664
   likes_nb: 77065
@@ -117,13 +124,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 20527
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: You got this
   timestamp: 2019-01-16 16:08:00
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 553
+  fullname: Twitter
   hashtag_list: []
   id: 1085265146644058112
   likes_nb: 4255
@@ -136,7 +144,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 1060
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: Android, we got you. Starting today, tap  to switch between latest and top
     Tweets.pic.twitter.com/7rXo3BNEJ6
@@ -144,6 +152,7 @@
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 3320
+  fullname: Twitter
   hashtag_list: []
   id: 1084982024794861568
   likes_nb: 48030
@@ -156,13 +165,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 8234
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: brb
   timestamp: 2019-01-15 01:14:07
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 9137
+  fullname: Twitter
   hashtag_list: []
   id: 1083581799467442177
   likes_nb: 138039
@@ -175,13 +185,14 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 36589
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: Go to sleep
   timestamp: 2019-01-11 04:30:07
   user_id: 783214
 - !!python/object:twhatter.parser.tweet.TweetTextOnly
   comments_nb: 9685
+  fullname: Twitter
   hashtag_list: []
   id: 1082713943200751616
   likes_nb: 175003
@@ -194,7 +205,7 @@
   retweet_id: null
   retweeter: null
   retweets_nb: 55540
-  screen_name: Twitter
+  username: Twitter
   soup: null
   text: Hahahahahahahaha
   timestamp: 2019-01-08 19:01:34