From 55b589bedc6156b8fec8d35d78af4ceff2929abb Mon Sep 17 00:00:00 2001 From: Jonas Kubeler Date: Sun, 23 Jun 2024 14:47:46 +0200 Subject: [PATCH] added a few additional test criteria to message tests --- .../TCCImageStore.class/methodProperties.json | 8 +++++++- .../TCCStickerMessage.class/instance/asSnippet.st | 2 +- .../TCCStickerMessage.class/methodProperties.json | 2 +- .../TCCStickerStore.class/methodProperties.json | 10 +++++++++- .../TCCVideoStore.class/methodProperties.json | 5 ++++- .../TCUStickerList.class/methodProperties.json | 5 +++++ ...atedStickerMessageCorrectlyConstructedFromJson.st | 4 +++- .../testPhotoMessageCorrectlyConstructedFromJson.st | 4 +++- ...taticStickerMessageCorrectlyContructedFromJson.st | 4 +++- .../testTextMessageTypeIdentifiedCorrectly.st | 4 +++- .../testVideoMessageCorrectlyConstructedFromJson.st | 4 +++- .../TCTCMessageTests.class/methodProperties.json | 12 ++++++------ 12 files changed, 48 insertions(+), 16 deletions(-) diff --git a/packages/TelegramClient-Core.package/TCCImageStore.class/methodProperties.json b/packages/TelegramClient-Core.package/TCCImageStore.class/methodProperties.json index 45df6bf00..04936fe29 100644 --- a/packages/TelegramClient-Core.package/TCCImageStore.class/methodProperties.json +++ b/packages/TelegramClient-Core.package/TCCImageStore.class/methodProperties.json @@ -1,5 +1,11 @@ { "class" : { - }, + "extractPathFrom:" : " 6/23/2024 14:02:55", + "imageFormFrom:" : " 6/23/2024 14:02:55", + "newWith:" : " 6/23/2024 14:02:55" }, "instance" : { + "core" : " 6/23/2024 14:02:55", + "core:" : " 6/23/2024 14:02:55", + "getFormFor:" : " 6/23/2024 14:02:55", + "getFormPromiseFor:" : " 6/23/2024 14:02:55", "requestImageFor:with:" : "6/22/2024 13:42:57" } } diff --git a/packages/TelegramClient-Core.package/TCCStickerMessage.class/instance/asSnippet.st b/packages/TelegramClient-Core.package/TCCStickerMessage.class/instance/asSnippet.st index 0523cf614..29a78d2e3 100644 --- a/packages/TelegramClient-Core.package/TCCStickerMessage.class/instance/asSnippet.st +++ b/packages/TelegramClient-Core.package/TCCStickerMessage.class/instance/asSnippet.st @@ -1,4 +1,4 @@ accessing asSnippet - ^ 'Sticker' \ No newline at end of file + ^ 'Sticker: ', self stickerId \ No newline at end of file diff --git a/packages/TelegramClient-Core.package/TCCStickerMessage.class/methodProperties.json b/packages/TelegramClient-Core.package/TCCStickerMessage.class/methodProperties.json index cce0f4958..cfb2db6b3 100644 --- a/packages/TelegramClient-Core.package/TCCStickerMessage.class/methodProperties.json +++ b/packages/TelegramClient-Core.package/TCCStickerMessage.class/methodProperties.json @@ -3,7 +3,7 @@ "newAnimatedStickerFrom:" : "JK 5/31/2024 11:36", "newFrom:" : "JK 6/23/2024 11:39" }, "instance" : { - "asSnippet" : "JK 5/16/2024 16:00", + "asSnippet" : "JK 6/23/2024 14:32", "asText" : "JK 5/16/2024 16:00", "height" : "JK 5/16/2024 16:01", "height:" : "JK 5/16/2024 16:01", diff --git a/packages/TelegramClient-Core.package/TCCStickerStore.class/methodProperties.json b/packages/TelegramClient-Core.package/TCCStickerStore.class/methodProperties.json index 9f520c994..31a555c0f 100644 --- a/packages/TelegramClient-Core.package/TCCStickerStore.class/methodProperties.json +++ b/packages/TelegramClient-Core.package/TCCStickerStore.class/methodProperties.json @@ -1,12 +1,20 @@ { "class" : { + "extractPathFrom:" : " 6/23/2024 14:02:55", "imageFormFrom:" : "JK 6/21/2024 13:46", - "newWith:" : "JK 6/20/2024 22:18" }, + "newWith:" : "JK 6/20/2024 22:18", + "stickerFormFrom:" : " 6/23/2024 14:02:55" }, "instance" : { + "core" : " 6/23/2024 14:02:55", + "core:" : " 6/23/2024 14:02:55", "downloadStickerSet:" : "JK 6/19/2024 11:33", + "getFormFor:" : " 6/23/2024 14:02:55", + "getFormPromiseFor:" : " 6/23/2024 14:02:55", "getInstalledStickers" : "JK 6/5/2024 11:37", "loadStickerIds" : "JK 6/20/2024 23:39", "requestStickerFor:with:" : "JK 5/16/2024 21:40", + "stickerIds" : " 6/23/2024 14:02:55", + "stickerIds:" : " 6/23/2024 14:02:55", "stickerSets" : "JK 6/19/2024 11:30", "stickerSets:" : "JK 6/19/2024 11:30", "storeStickerSet:" : "JK 6/19/2024 11:44" } } diff --git a/packages/TelegramClient-Core.package/TCCVideoStore.class/methodProperties.json b/packages/TelegramClient-Core.package/TCCVideoStore.class/methodProperties.json index 8085d52e6..f51dc903c 100644 --- a/packages/TelegramClient-Core.package/TCCVideoStore.class/methodProperties.json +++ b/packages/TelegramClient-Core.package/TCCVideoStore.class/methodProperties.json @@ -1,6 +1,9 @@ { "class" : { - }, + "extractPathFrom:" : " 6/23/2024 14:02:55", + "imageFormFrom:" : " 6/23/2024 14:02:55" }, "instance" : { + "getFormFor:" : " 6/23/2024 14:02:55", + "getFormPromiseFor:" : " 6/23/2024 14:02:55", "getVideoFor:" : "JK 6/12/2024 19:48", "getVideoPromiseFor:" : "JK 6/12/2024 19:56" } } diff --git a/packages/TelegramClient-UI.package/TCUStickerList.class/methodProperties.json b/packages/TelegramClient-UI.package/TCUStickerList.class/methodProperties.json index 291d14189..b4b9cb476 100644 --- a/packages/TelegramClient-UI.package/TCUStickerList.class/methodProperties.json +++ b/packages/TelegramClient-UI.package/TCUStickerList.class/methodProperties.json @@ -5,12 +5,17 @@ "addCloseButton" : "JK 5/21/2024 10:22", "addNextButton" : "JK 6/19/2024 12:03", "addPreviousButton" : "JK 6/19/2024 12:04", + "buildStickerListItems" : " 6/23/2024 14:02:54", "buildStickerListItemsFor:" : "JK 6/21/2024 14:07", "close" : "JK 5/29/2024 20:09", + "collectInstalledStickers" : " 6/23/2024 14:02:54", "convertWebp:" : "6/22/2024 13:42:57", "core" : "JK 5/31/2024 14:29", "core:" : "JK 5/31/2024 14:29", + "downloadStickerSetFrom:" : " 6/23/2024 14:02:54", "initialize" : "JK 6/20/2024 23:42", + "loadStickers" : " 6/23/2024 14:02:54", + "loadStickersFromStore" : " 6/23/2024 14:02:54", "selectedChat" : "JK 5/28/2024 10:22", "selectedChat:" : "JK 5/28/2024 10:23", "selectedSet" : "JK 6/20/2024 11:39", diff --git a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testAnimatedStickerMessageCorrectlyConstructedFromJson.st b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testAnimatedStickerMessageCorrectlyConstructedFromJson.st index 258d481a7..34cf9b098 100644 --- a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testAnimatedStickerMessageCorrectlyConstructedFromJson.st +++ b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testAnimatedStickerMessageCorrectlyConstructedFromJson.st @@ -7,4 +7,6 @@ testAnimatedStickerMessageCorrectlyConstructedFromJson stickerMessageEvent := TCTMMocks mockAnimatedStickerMessageJsonFrom: chat id. stickerMessage := TCCMessage newFromMessageEvent: stickerMessageEvent in: chat with: self core. - self assert: TCTMMocks mockValidEmoji equals: stickerMessage text. \ No newline at end of file + self assert: TCTMMocks mockValidEmoji equals: stickerMessage text. + self assert: TCTMMocks mockValidEmoji equals: stickerMessage asSnippet. + self assert: TCTMMocks mockValidEmoji equals: stickerMessage asText. \ No newline at end of file diff --git a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testPhotoMessageCorrectlyConstructedFromJson.st b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testPhotoMessageCorrectlyConstructedFromJson.st index 5cae7fa86..59f9f9a89 100644 --- a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testPhotoMessageCorrectlyConstructedFromJson.st +++ b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testPhotoMessageCorrectlyConstructedFromJson.st @@ -8,7 +8,9 @@ testPhotoMessageCorrectlyConstructedFromJson photoMessage := TCCMessage newFromMessageEvent: photoMessageEvent in: chat with: self core. self assert: TCTMMocks mockText equals: photoMessage caption. + self assert: TCTMMocks mockText equals: photoMessage asText. self assert: photoMessage hasCaption. self assert: TCTMMocks mockImageId equals: photoMessage fileId. self assert: TCTMMocks mockPhotoHeight equals: photoMessage height. - self assert: TCTMMocks mockPhotoWidth equals: photoMessage width. \ No newline at end of file + self assert: TCTMMocks mockPhotoWidth equals: photoMessage width. + self assert: 'Photo: ', TCTMMocks mockText equals: photoMessage asSnippet. \ No newline at end of file diff --git a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testStaticStickerMessageCorrectlyContructedFromJson.st b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testStaticStickerMessageCorrectlyContructedFromJson.st index dd056198b..61e13bd1a 100644 --- a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testStaticStickerMessageCorrectlyContructedFromJson.st +++ b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testStaticStickerMessageCorrectlyContructedFromJson.st @@ -9,4 +9,6 @@ testStaticStickerMessageCorrectlyContructedFromJson self assert: TCTMMocks mockStickerId equals: stickerMessage stickerId. self assert: TCTMMocks mockStickerWidth equals: stickerMessage width. - self assert: TCTMMocks mockStickerHeight equals: stickerMessage height. \ No newline at end of file + self assert: TCTMMocks mockStickerHeight equals: stickerMessage height. + self assert: 'Sticker: ', TCTMMocks mockStickerId equals: stickerMessage asSnippet. + self assert: 'Sticker' equals: stickerMessage asText. \ No newline at end of file diff --git a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testTextMessageTypeIdentifiedCorrectly.st b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testTextMessageTypeIdentifiedCorrectly.st index 22bdf9d65..2e42c270d 100644 --- a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testTextMessageTypeIdentifiedCorrectly.st +++ b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testTextMessageTypeIdentifiedCorrectly.st @@ -7,4 +7,6 @@ testTextMessageTypeIdentifiedCorrectly textMessageEvent := TCTMMocks mockMessageJsonFrom: chat id. textMessage := TCCMessage newFromMessageEvent: textMessageEvent in: chat with: self core. - self assert: TCCTextMessage equals: textMessage class. \ No newline at end of file + self assert: TCCTextMessage equals: textMessage class. + self assert: TCTMMocks mockText equals: textMessage asSnippet. + self assert: TCTMMocks mockText equals: textMessage asText. \ No newline at end of file diff --git a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testVideoMessageCorrectlyConstructedFromJson.st b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testVideoMessageCorrectlyConstructedFromJson.st index c65831a2a..19107e462 100644 --- a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testVideoMessageCorrectlyConstructedFromJson.st +++ b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/instance/testVideoMessageCorrectlyConstructedFromJson.st @@ -12,4 +12,6 @@ testVideoMessageCorrectlyConstructedFromJson self assert: TCTMMocks mockImageId equals: videoMessage thumbnailId. self assert: TCTMMocks mockPhotoHeight equals: videoMessage height. self assert: TCTMMocks mockPhotoWidth equals: videoMessage width. - self assert: TCTMMocks mockVideoId equals: videoMessage videoId. \ No newline at end of file + self assert: TCTMMocks mockVideoId equals: videoMessage videoId. + self assert: 'Video: ', TCTMMocks mockText equals: videoMessage asSnippet. + self assert: TCTMMocks mockText equals: videoMessage asText. \ No newline at end of file diff --git a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/methodProperties.json b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/methodProperties.json index 16572765b..089f525dc 100644 --- a/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/methodProperties.json +++ b/packages/TelegramClientTests-Core.package/TCTCMessageTests.class/methodProperties.json @@ -2,7 +2,7 @@ "class" : { }, "instance" : { - "testAnimatedStickerMessageCorrectlyConstructedFromJson" : "JK 6/23/2024 11:49", + "testAnimatedStickerMessageCorrectlyConstructedFromJson" : "JK 6/23/2024 14:35", "testAnimatedStickerMessageTypeIdentifiedCorrectly" : "JK 6/23/2024 11:45", "testDocumentMessageCorrectlyConstructedFromJson" : "JK 6/23/2024 12:01", "testDocumentMessageTypeIdentifiedCorrectly" : "JK 6/23/2024 11:55", @@ -17,13 +17,13 @@ "testMessageShouldNotify" : "RS 7/17/2021 10:53", "testMessageWithMessageSenderChatCorrectlyConstructedFromJson" : "js 7/31/2022 10:29", "testNotSupportedMessageTypeIdentifiedCorrectly" : "js 7/31/2022 10:29", - "testPhotoMessageCorrectlyConstructedFromJson" : "js 7/31/2022 10:29", + "testPhotoMessageCorrectlyConstructedFromJson" : "JK 6/23/2024 14:31", "testPhotoMessageTypeIdentifiedCorrectly" : "JK 6/23/2024 11:26", "testSenderNameInChannelMessage" : "tom.richter 7/25/2021 11:36", "testSenderNameInNonChannelMessage" : "per 7/17/2021 16:13", - "testStaticStickerMessageCorrectlyContructedFromJson" : "JK 6/23/2024 11:43", - "testStaticStickerMessageTypeIdentifiedCorrectly" : "JK 6/23/2024 11:30", + "testStaticStickerMessageCorrectlyContructedFromJson" : "JK 6/23/2024 14:34", + "testStaticStickerMessageTypeIdentifiedCorrectly" : "JK 6/23/2024 14:34", "testTextMessageCorrectlyConstructedFromJson" : "js 7/31/2022 10:30", - "testTextMessageTypeIdentifiedCorrectly" : "js 7/31/2022 10:30", - "testVideoMessageCorrectlyConstructedFromJson" : "JK 6/23/2024 11:12", + "testTextMessageTypeIdentifiedCorrectly" : "JK 6/23/2024 14:32", + "testVideoMessageCorrectlyConstructedFromJson" : "JK 6/23/2024 14:31", "testVideoMessageTypeIdentifiedCorrectly" : "JK 6/23/2024 11:24" } }