Skip to content

Commit 758dab3

Browse files
author
RoFlection Bot
committed
upgrade deps (#69)
1 parent c4283e2 commit 758dab3

File tree

5 files changed

+21
-24
lines changed

5 files changed

+21
-24
lines changed

foreman.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
rojo = { source = "rojo-rbx/rojo", version = "7.2.1" }
33
rotrieve = { source = "roblox/rotriever", version = "0.5.4" }
44
selene = { source = "Kampfkarren/selene", version = "0.20.0" }
5-
stylua = { source = "JohnnyMorganz/StyLua", version = "0.14.2" }
5+
stylua = { source = "JohnnyMorganz/StyLua", version = "=0.14.3" }

rotriever.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ LuauPolyfill = "github.com/roblox/luau-polyfill@0.3.4"
1111
LuauRegExp = "github.com/Roblox/luau-regexp@0.2.0"
1212
Chalk = "github.com/roblox/chalk-lua@0.1.3"
1313
Promise = "github.com/evaera/roblox-lua-promise@4.0.0"
14-
JestGetType = { git = "https://github.com/roblox/jest-roblox.git", rev="master", package="JestGetType"}
15-
PrettyFormat = { git = "https://github.com/roblox/jest-roblox.git", rev="master", package="PrettyFormat"}
16-
RobloxShared = { git = "https://github.com/roblox/jest-roblox.git", rev="master", package="RobloxShared"}
14+
JestGetType = "github.com/roblox/jest-roblox@3.0.0-alpha"
15+
PrettyFormat = "github.com/roblox/jest-roblox@3.0.0-alpha"
16+
RobloxShared = "github.com/roblox/jest-roblox@3.0.0-alpha"
1717
JestGlobals = "github.com/roblox/jest-roblox@3.0.0-alpha"
1818

1919
[dev_dependencies]
20-
Jest = { git = "https://github.com/roblox/jest-roblox.git", version="3.0.0-alpha", package="Jest" }
20+
Jest = "github.com/roblox/jest-roblox@3.0.0-alpha"

src/queries/text.lua

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,7 @@ function getMissingError(c, text: Matcher, options_: SelectorMatcherOptions?)
8585
})
8686
local normalizedText = matchNormalizer(tostring(text))
8787
local isNormalizedDifferent = normalizedText ~= tostring(text)
88-
return (
89-
"Unable to find an element with the text: %s. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible."
90-
):format(
88+
return ("Unable to find an element with the text: %s. This could be because the text is broken up by multiple elements. In this case, you can provide a function for your text matcher to make your matcher more flexible."):format(
9189
tostring(
9290
if isNormalizedDifferent then ("%s (normalized from '%s')"):format(normalizedText, tostring(text)) else text
9391
)

src/query-helpers.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ end
4646

4747
local function getMultipleElementsFoundError(message: string, container: Instance)
4848
return getElementError(
49-
(
50-
"%s\n\n(If this is intentional, then use the `*AllBy*` variant of the query (like `queryAllByText`, `getAllByText`, or `findAllByText`))."
51-
):format(message),
49+
("%s\n\n(If this is intentional, then use the `*AllBy*` variant of the query (like `queryAllByText`, `getAllByText`, or `findAllByText`))."):format(
50+
message
51+
),
5252
container
5353
)
5454
end

src/screen.lua

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -84,19 +84,18 @@ local initialValue = { debug = debug_, logTestingPlaygroundURL = logTestingPlayg
8484
local screen = if typeof(document)
8585
~= "nil" -- eslint-disable-line @typescript-eslint/no-unnecessary-condition -- eslint-disable-line @typescript-eslint/no-unnecessary-condition)
8686
then getQueriesForElement(document, queries, initialValue)
87-
else
88-
Array.reduce(Object.keys(queries), function(helpers, key)
89-
-- `key` is for all intents and purposes the type of keyof `helpers`, which itself is the type of `initialValue` plus incoming properties from `queries`
90-
-- if `Object.keys(something)` returned Array<keyof typeof something> this explicit type assertion would not be necessary
91-
-- see https://stackoverflow.com/questions/55012174/why-doesnt-object-keys-return-a-keyof-type-in-typescript
92-
helpers[key] = function()
93-
error(
94-
TypeError.new(
95-
"For queries bound to document.body a global document has to be available... Learn more: https://testing-library.com/s/screen-global-error"
96-
)
87+
else Array.reduce(Object.keys(queries), function(helpers, key)
88+
-- `key` is for all intents and purposes the type of keyof `helpers`, which itself is the type of `initialValue` plus incoming properties from `queries`
89+
-- if `Object.keys(something)` returned Array<keyof typeof something> this explicit type assertion would not be necessary
90+
-- see https://stackoverflow.com/questions/55012174/why-doesnt-object-keys-return-a-keyof-type-in-typescript
91+
helpers[key] = function()
92+
error(
93+
TypeError.new(
94+
"For queries bound to document.body a global document has to be available... Learn more: https://testing-library.com/s/screen-global-error"
9795
)
98-
end
99-
return helpers
100-
end, initialValue)
96+
)
97+
end
98+
return helpers
99+
end, initialValue)
101100
exports.screen = screen
102101
return exports

0 commit comments

Comments
 (0)