code
stringlengths 26
870k
| docstring
stringlengths 1
65.6k
| func_name
stringlengths 1
194
| language
stringclasses 1
value | repo
stringlengths 8
68
| path
stringlengths 5
194
| url
stringlengths 46
254
| license
stringclasses 4
values |
---|---|---|---|---|---|---|---|
async def test_edgeql_sparsevec_cast_01(self):
# Basic casts to and from json.
await self.assert_query_result(
'''
with module ext::pgvector
select <json><sparsevec><vector>[0, 2, 3.5, 0];
''',
[{"1": 2, "2": 3.5, "dim": 4}],
json_only=True,
)
await self.assert_query_result(
'''
with module ext::pgvector
select <array<float32>><vector><sparsevec>
to_json('{"dim": 4, "1": 2, "2": 3.5}');
''',
[[0, 2, 3.5, 0]],
)
async with self.assertRaisesRegexTx(
edgedb.errors.InvalidValueError,
'object expected',
):
await self.con.execute(r"""
with module ext::pgvector
select <sparsevec>to_json('[4,2]');
""")
async with self.assertRaisesRegexTx(
edgedb.errors.InvalidValueError,
'object expected',
):
await self.con.execute(r"""
with module ext::pgvector
select <sparsevec>to_json('null');
""")
async with self.assertRaisesRegexTx(
edgedb.errors.InvalidValueError,
'missing "dim"',
):
await self.con.execute(r"""
with module ext::pgvector
select <sparsevec>to_json('{"0": 4, "1": 2, "2": 3.5}');
""")
async with self.assertRaisesRegexTx(
edgedb.errors.InvalidValueError,
'unexpected key',
):
await self.con.execute(r"""
with module ext::pgvector
select <sparsevec>to_json('{"z": 4, "dim": 2, "2": 3.5}');
""") | with module ext::pgvector
select <json><sparsevec><vector>[0, 2, 3.5, 0];
''',
[{"1": 2, "2": 3.5, "dim": 4}],
json_only=True,
)
await self.assert_query_result( | test_edgeql_sparsevec_cast_01 | python | geldata/gel | tests/test_edgeql_vector.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_vector.py | Apache-2.0 |
async def test_edgeql_sparsevec_cast_02(self):
# str casts
await self.assert_query_result(
'''
select <json><sv3>'{1:3.5}/3';
''',
[{"1": 3.5, "dim": 3}],
json_only=True,
)
await self.assert_query_result(
'''
select <str><sv3><ext::pgvector::vector>[0, 3.5, 0];
''',
['{1:3.5}/3'],
) | select <json><sv3>'{1:3.5}/3';
''',
[{"1": 3.5, "dim": 3}],
json_only=True,
)
await self.assert_query_result( | test_edgeql_sparsevec_cast_02 | python | geldata/gel | tests/test_edgeql_vector.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_vector.py | Apache-2.0 |
async def test_edgeql_sparsevec_cast_03(self):
# str casts
await self.assert_query_result(
'''
with module ext::pgvector
select <json><sparsevec>
' { 4 : 3.5e-6 } / 5 ';
''',
[{"4": 3.5e-6, "dim": 5}],
json_only=True,
)
async with self.assertRaisesRegexTx(
edgedb.errors.InvalidValueError,
'invalid input syntax',
):
await self.con.execute(r"""
with module ext::pgvector
select <sparsevec>'{4:2}';
""")
async with self.assertRaisesRegexTx(
edgedb.errors.InvalidValueError,
'invalid input syntax',
):
await self.con.execute(r"""
with module ext::pgvector
select <sparsevec>'[4:2]';
""") | with module ext::pgvector
select <json><sparsevec>
' { 4 : 3.5e-6 } / 5 ';
''',
[{"4": 3.5e-6, "dim": 5}],
json_only=True,
)
async with self.assertRaisesRegexTx(
edgedb.errors.InvalidValueError,
'invalid input syntax',
):
await self.con.execute(r | test_edgeql_sparsevec_cast_03 | python | geldata/gel | tests/test_edgeql_vector.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_vector.py | Apache-2.0 |
async def _check_sv_index(self, obj, func, index_type, index_op):
# Sparse vectors have differernt casts from regular vectors, so they
# need different queries for this test
obj_id = (await self.con.query_single(f"""
insert {obj} {{
vec := <sv3><v3>[1, 1, 0]
}}
""")).id
await self.con.execute(f"""
insert {obj} {{
vec := <sv3><v3>[0, -1, 0]
}}
""")
embedding = '{1:-0.1}/3'
await self._assert_index_use(
f'''
with vec as module ext::pgvector,
base := (select {obj} filter .id = <uuid>$0),
select {obj}
filter {obj}.id != base.id
order by vec::{func}(.vec, base.vec)
empty last limit 5;
''',
obj_id,
index_type=index_type,
index_op=index_op,
)
await self._assert_index_use(
f'''
with vec as module ext::pgvector
select {obj}
order by vec::{func}(.vec, <sv3><str>$0)
empty last limit 5;
''',
embedding,
index_type=index_type,
index_op=index_op,
)
await self._assert_index_use(
f'''
with vec as module ext::pgvector
select {obj}
order by vec::{func}(.vec, <sv3><json>$0)
empty last limit 5;
''',
json.dumps({'1': -0.1, 'dim': 3}),
index_type=index_type,
index_op=index_op,
) | )).id
await self.con.execute(f | _check_sv_index | python | geldata/gel | tests/test_edgeql_vector.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_vector.py | Apache-2.0 |
async def test_edgeql_vector_drop_extension_with_func_cache(self):
await self.con.execute("create extension pgvector")
try:
# Run many times to wait for the func cache creation
for _i in range(64):
await self.con.query(
'''
select <ext::pgvector::vector>[4.2];
'''
)
finally:
# this should drop the cache function of the query above as well
await self.con.execute("drop extension pgvector") | select <ext::pgvector::vector>[4.2]; | test_edgeql_vector_drop_extension_with_func_cache | python | geldata/gel | tests/test_edgeql_vector.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_vector.py | Apache-2.0 |
def test_edgeql_ir_card_inference_00(self):
"""
SELECT Card
% OK %
MANY
""" | SELECT Card
% OK %
MANY | test_edgeql_ir_card_inference_00 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_01(self):
"""
SELECT Card FILTER Card.name = 'Djinn'
% OK %
AT_MOST_ONE
""" | SELECT Card FILTER Card.name = 'Djinn'
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_01 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_02(self):
"""
SELECT Card FILTER 'Djinn' = Card.name
% OK %
AT_MOST_ONE
""" | SELECT Card FILTER 'Djinn' = Card.name
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_02 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_03(self):
"""
SELECT Card FILTER 'foo' = 'foo' AND 'Djinn' = Card.name
% OK %
AT_MOST_ONE
""" | SELECT Card FILTER 'foo' = 'foo' AND 'Djinn' = Card.name
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_03 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_04(self):
"""
SELECT Card FILTER 'foo' = 'foo' OR 'Djinn' = Card.name
% OK %
MANY
""" | SELECT Card FILTER 'foo' = 'foo' OR 'Djinn' = Card.name
% OK %
MANY | test_edgeql_ir_card_inference_04 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_05(self):
"""
SELECT Card FILTER Card.id = <uuid>'...'
% OK %
AT_MOST_ONE
""" | SELECT Card FILTER Card.id = <uuid>'...'
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_05 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_06(self):
"""
WITH C2 := Card
SELECT Card FILTER Card = (SELECT C2 FILTER C2.name = 'Djinn')
% OK %
AT_MOST_ONE
""" | WITH C2 := Card
SELECT Card FILTER Card = (SELECT C2 FILTER C2.name = 'Djinn')
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_06 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_07(self):
"""
WITH C2 := DETACHED Card
SELECT Card FILTER Card = (SELECT C2 FILTER C2.name = 'Djinn')
% OK %
AT_MOST_ONE
""" | WITH C2 := DETACHED Card
SELECT Card FILTER Card = (SELECT C2 FILTER C2.name = 'Djinn')
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_07 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_08(self):
"""
SELECT Card LIMIT 1
% OK %
AT_MOST_ONE
""" | SELECT Card LIMIT 1
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_08 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_09(self):
"""
SELECT Card FILTER Card.<deck[IS User].name = 'Bob'
% OK %
MANY
""" | SELECT Card FILTER Card.<deck[IS User].name = 'Bob'
% OK %
MANY | test_edgeql_ir_card_inference_09 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_10(self):
"""
SELECT 1
% OK %
ONE
""" | SELECT 1
% OK %
ONE | test_edgeql_ir_card_inference_10 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_11(self):
"""
SELECT {1, 2, 3}
% OK %
AT_LEAST_ONE
""" | SELECT {1, 2, 3}
% OK %
AT_LEAST_ONE | test_edgeql_ir_card_inference_11 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_12(self):
"""
SELECT {1, 2, 3, Card.cost}
% OK %
AT_LEAST_ONE
""" | SELECT {1, 2, 3, Card.cost}
% OK %
AT_LEAST_ONE | test_edgeql_ir_card_inference_12 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_13(self):
"""
SELECT array_agg({1, 2, 3})
% OK %
ONE
""" | SELECT array_agg({1, 2, 3})
% OK %
ONE | test_edgeql_ir_card_inference_13 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_14(self):
"""
SELECT array_agg(Card.cost)
% OK %
ONE
""" | SELECT array_agg(Card.cost)
% OK %
ONE | test_edgeql_ir_card_inference_14 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_15(self):
"""
SELECT to_str(Card.cost)
% OK %
MANY
""" | SELECT to_str(Card.cost)
% OK %
MANY | test_edgeql_ir_card_inference_15 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_16(self):
"""
SELECT to_str((SELECT Card.cost LIMIT 1))
% OK %
AT_MOST_ONE
""" | SELECT to_str((SELECT Card.cost LIMIT 1))
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_16 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_17(self):
"""
SELECT to_str({1, (SELECT Card.cost LIMIT 1)})
% OK %
AT_LEAST_ONE
""" | SELECT to_str({1, (SELECT Card.cost LIMIT 1)})
% OK %
AT_LEAST_ONE | test_edgeql_ir_card_inference_17 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_18(self):
"""
SELECT to_str(1)
% OK %
ONE
""" | SELECT to_str(1)
% OK %
ONE | test_edgeql_ir_card_inference_18 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_19(self):
"""
SELECT 1 + 2
% OK %
ONE
""" | SELECT 1 + 2
% OK %
ONE | test_edgeql_ir_card_inference_19 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_20(self):
"""
SELECT 1 + (2 UNION 3)
% OK %
AT_LEAST_ONE
""" | SELECT 1 + (2 UNION 3)
% OK %
AT_LEAST_ONE | test_edgeql_ir_card_inference_20 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_21(self):
"""
SELECT 1 + Card.cost
% OK %
MANY
""" | SELECT 1 + Card.cost
% OK %
MANY | test_edgeql_ir_card_inference_21 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_22(self):
"""
SELECT (SELECT Card LIMIT 1).cost ?? 99
% OK %
ONE
""" | SELECT (SELECT Card LIMIT 1).cost ?? 99
% OK %
ONE | test_edgeql_ir_card_inference_22 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_23(self):
"""
SELECT (SELECT Card LIMIT 1).element ?? (SELECT User LIMIT 1).name
% OK %
AT_MOST_ONE
""" | SELECT (SELECT Card LIMIT 1).element ?? (SELECT User LIMIT 1).name
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_23 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_24(self):
"""
SELECT (SELECT Card LIMIT 1).element ?= 'fire'
% OK %
ONE
""" | SELECT (SELECT Card LIMIT 1).element ?= 'fire'
% OK %
ONE | test_edgeql_ir_card_inference_24 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_25(self):
"""
SELECT Named {
name
}
% OK %
name: ONE
""" | SELECT Named {
name
}
% OK %
name: ONE | test_edgeql_ir_card_inference_25 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_26(self):
"""
SELECT User {
foo := .name
}
% OK %
foo: ONE
""" | SELECT User {
foo := .name
}
% OK %
foo: ONE | test_edgeql_ir_card_inference_26 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_27(self):
"""
SELECT User {
foo := 'prefix_' ++ .name
}
% OK %
foo: ONE
""" | SELECT User {
foo := 'prefix_' ++ .name
}
% OK %
foo: ONE | test_edgeql_ir_card_inference_27 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_28(self):
"""
SELECT User {
deck_cost
}
% OK %
deck_cost: ONE
""" | SELECT User {
deck_cost
}
% OK %
deck_cost: ONE | test_edgeql_ir_card_inference_28 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_29(self):
"""
SELECT User {
dc := sum(.deck.cost)
}
% OK %
dc: ONE
""" | SELECT User {
dc := sum(.deck.cost)
}
% OK %
dc: ONE | test_edgeql_ir_card_inference_29 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_30(self):
"""
SELECT User {
deck
}
% OK %
deck: MANY
""" | SELECT User {
deck
}
% OK %
deck: MANY | test_edgeql_ir_card_inference_30 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_31(self):
"""
SELECT Card {
owners
}
% OK %
owners: MANY
""" | SELECT Card {
owners
}
% OK %
owners: MANY | test_edgeql_ir_card_inference_31 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_32(self):
"""
WITH
A := (SELECT Award LIMIT 1)
# the "awards" are exclusive
SELECT A.<awards[IS User]
% OK %
AT_MOST_ONE
""" | WITH
A := (SELECT Award LIMIT 1)
# the "awards" are exclusive
SELECT A.<awards[IS User]
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_32 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_33(self):
"""
SELECT Award {
# the "awards" are exclusive
recipient := .<awards[IS User]
}
% OK %
recipient: AT_MOST_ONE
""" | SELECT Award {
# the "awards" are exclusive
recipient := .<awards[IS User]
}
% OK %
recipient: AT_MOST_ONE | test_edgeql_ir_card_inference_33 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_34(self):
"""
SELECT Award {
rec
}
% OK %
rec: AT_MOST_ONE
""" | SELECT Award {
rec
}
% OK %
rec: AT_MOST_ONE | test_edgeql_ir_card_inference_34 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_35(self):
"""
SELECT AwardAlias {
recipient
}
% OK %
recipient: AT_MOST_ONE
""" | SELECT AwardAlias {
recipient
}
% OK %
recipient: AT_MOST_ONE | test_edgeql_ir_card_inference_35 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_36(self):
"""
SELECT Eert {
parent
}
% OK %
parent: AT_MOST_ONE
""" | SELECT Eert {
parent
}
% OK %
parent: AT_MOST_ONE | test_edgeql_ir_card_inference_36 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_36b(self):
"""
SELECT Eert {
asdf := .<children[is Eert]
}
% OK %
asdf: AT_MOST_ONE
""" | SELECT Eert {
asdf := .<children[is Eert]
}
% OK %
asdf: AT_MOST_ONE | test_edgeql_ir_card_inference_36b | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_36c(self):
"""
SELECT Eert {
asdf := .<children[is Asdf]
}
% OK %
asdf: MANY
""" | SELECT Eert {
asdf := .<children[is Asdf]
}
% OK %
asdf: MANY | test_edgeql_ir_card_inference_36c | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_36d(self):
"""
SELECT Eert {
asdf := .<children[is Object]
}
% OK %
asdf: MANY
""" | SELECT Eert {
asdf := .<children[is Object]
}
% OK %
asdf: MANY | test_edgeql_ir_card_inference_36d | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_37(self):
"""
SELECT Report {
user_name := .user.name
}
% OK %
user_name: ONE
""" | SELECT Report {
user_name := .user.name
}
% OK %
user_name: ONE | test_edgeql_ir_card_inference_37 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_38(self):
"""
SELECT Report {
name := .user.name
}
% OK %
name: ONE
""" | SELECT Report {
name := .user.name
}
% OK %
name: ONE | test_edgeql_ir_card_inference_38 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_39(self):
"""
SELECT Report {
name := <str>{}
}
""" | SELECT Report {
name := <str>{}
} | test_edgeql_ir_card_inference_39 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_40(self):
"""
SELECT Report {
single foo := User.name
}
""" | SELECT Report {
single foo := User.name
} | test_edgeql_ir_card_inference_40 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_41(self):
"""
SELECT User.deck@count
% OK %
MANY
""" | SELECT User.deck@count
% OK %
MANY | test_edgeql_ir_card_inference_41 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_42(self):
"""
SELECT Report.user@note
% OK %
MANY
""" | SELECT Report.user@note
% OK %
MANY | test_edgeql_ir_card_inference_42 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_43(self):
"""
SELECT User {
foo := .deck@count
}
% OK %
foo: MANY
""" | SELECT User {
foo := .deck@count
}
% OK %
foo: MANY | test_edgeql_ir_card_inference_43 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_44(self):
"""
SELECT Report {
foo := .user@note
}
% OK %
foo: AT_MOST_ONE
""" | SELECT Report {
foo := .user@note
}
% OK %
foo: AT_MOST_ONE | test_edgeql_ir_card_inference_44 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_45(self):
"""
SELECT Report {
subtitle := 'aaa'
}
% OK %
subtitle: ONE
""" | SELECT Report {
subtitle := 'aaa'
}
% OK %
subtitle: ONE | test_edgeql_ir_card_inference_45 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_46(self):
"""
SELECT Named {
as_card := Named[IS Card]
}
% OK %
as_card: AT_MOST_ONE
""" | SELECT Named {
as_card := Named[IS Card]
}
% OK %
as_card: AT_MOST_ONE | test_edgeql_ir_card_inference_46 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_47(self):
"""
SELECT User {
foo := EXISTS(.friends)
}
% OK %
foo: ONE
""" | SELECT User {
foo := EXISTS(.friends)
}
% OK %
foo: ONE | test_edgeql_ir_card_inference_47 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_48(self):
"""
SELECT Card {
o_name := .owners.name,
}
% OK %
o_name: MANY
""" | SELECT Card {
o_name := .owners.name,
}
% OK %
o_name: MANY | test_edgeql_ir_card_inference_48 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_49(self):
"""
SELECT User {
name,
fire_deck := (
SELECT User.deck {name, element}
FILTER .element = 'Fire'
ORDER BY .name
).name
}
% OK %
fire_deck: MANY
""" | SELECT User {
name,
fire_deck := (
SELECT User.deck {name, element}
FILTER .element = 'Fire'
ORDER BY .name
).name
}
% OK %
fire_deck: MANY | test_edgeql_ir_card_inference_49 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_50(self):
"""
INSERT User {name := "Timmy"}
UNLESS CONFLICT
% OK %
AT_MOST_ONE
""" | INSERT User {name := "Timmy"}
UNLESS CONFLICT
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_50 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_51(self):
"""
INSERT User {name := "Johnny"}
UNLESS CONFLICT ON (.name)
ELSE User
% OK %
ONE
""" | INSERT User {name := "Johnny"}
UNLESS CONFLICT ON (.name)
ELSE User
% OK %
ONE | test_edgeql_ir_card_inference_51 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_52(self):
"""
INSERT User {name := "Spike"}
UNLESS CONFLICT ON (.name)
ELSE Card
% OK %
MANY
""" | INSERT User {name := "Spike"}
UNLESS CONFLICT ON (.name)
ELSE Card
% OK %
MANY | test_edgeql_ir_card_inference_52 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_53(self):
"""
INSERT User {name := "Madz"}
UNLESS CONFLICT ON (.name)
ELSE (DETACHED (INSERT User {name := "Madz2"}))
% OK %
ONE
""" | INSERT User {name := "Madz"}
UNLESS CONFLICT ON (.name)
ELSE (DETACHED (INSERT User {name := "Madz2"}))
% OK %
ONE | test_edgeql_ir_card_inference_53 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_54(self):
"""
SELECT Person FILTER .first = "Phil" AND .last = "Emarg"
% OK %
AT_MOST_ONE
""" | SELECT Person FILTER .first = "Phil" AND .last = "Emarg"
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_54 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_55(self):
"""
SELECT Person FILTER .first = "Phil"
% OK %
MANY
""" | SELECT Person FILTER .first = "Phil"
% OK %
MANY | test_edgeql_ir_card_inference_55 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_56(self):
"""
SELECT Person FILTER .email = "[email protected]"
% OK %
AT_MOST_ONE
""" | SELECT Person FILTER .email = "[email protected]"
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_56 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_57(self):
"""
SELECT Person { first } FILTER .p = 7 AND .q = 3
% OK %
AT_MOST_ONE
""" | SELECT Person { first } FILTER .p = 7 AND .q = 3
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_57 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_58(self):
"""
SELECT Person FILTER .last = "Hatch" AND .first = "Madeline"
% OK %
AT_MOST_ONE
""" | SELECT Person FILTER .last = "Hatch" AND .first = "Madeline"
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_58 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_59(self):
"""
SELECT Person FILTER .p = 7 AND .q = 3 AND .first = "???"
% OK %
AT_MOST_ONE
""" | SELECT Person FILTER .p = 7 AND .q = 3 AND .first = "???"
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_59 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_60(self):
"""
SELECT Person
FILTER .p = 12 AND .card = (SELECT Card FILTER .name = 'Imp')
% OK %
AT_MOST_ONE
""" | SELECT Person
FILTER .p = 12 AND .card = (SELECT Card FILTER .name = 'Imp')
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_60 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_60b(self):
"""
SELECT Person
FILTER .p = 12 AND .card.name = 'Imp'
% OK %
AT_MOST_ONE
""" | SELECT Person
FILTER .p = 12 AND .card.name = 'Imp'
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_60b | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_61(self):
"""
SELECT Person FILTER .first = "Phil" OR .last = "Emarg"
% OK %
MANY
""" | SELECT Person FILTER .first = "Phil" OR .last = "Emarg"
% OK %
MANY | test_edgeql_ir_card_inference_61 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_62(self):
"""
SELECT Person FILTER .p = 7 AND .q = 3 AND .last = "Whatever"
% OK %
AT_MOST_ONE
""" | SELECT Person FILTER .p = 7 AND .q = 3 AND .last = "Whatever"
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_62 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_63(self):
"""
WITH X := User { busted := (SELECT 1 ORDER BY {1,2}) },
SELECT X
""" | WITH X := User { busted := (SELECT 1 ORDER BY {1,2}) },
SELECT X | test_edgeql_ir_card_inference_63 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_64(self):
"""
SELECT (FOR x IN {1,2} UNION (SELECT User { m := x })) { m }
% OK %
m: ONE
""" | SELECT (FOR x IN {1,2} UNION (SELECT User { m := x })) { m }
% OK %
m: ONE | test_edgeql_ir_card_inference_64 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_65(self):
"""
SELECT (SELECT User { multi m := 1 }) { m }
% OK %
m: AT_LEAST_ONE
""" | SELECT (SELECT User { multi m := 1 }) { m }
% OK %
m: AT_LEAST_ONE | test_edgeql_ir_card_inference_65 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_66(self):
"""
WITH Z := (SELECT (SELECT User) ORDER BY .name), SELECT Z
% OK %
MANY
""" | WITH Z := (SELECT (SELECT User) ORDER BY .name), SELECT Z
% OK %
MANY | test_edgeql_ir_card_inference_66 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_67(self):
"""
SELECT { o := (SELECT (SELECT User) ORDER BY .name) }
% OK %
ONE
""" | SELECT { o := (SELECT (SELECT User) ORDER BY .name) }
% OK %
ONE | test_edgeql_ir_card_inference_67 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_68(self):
"""
SELECT 1 FILTER false
% OK %
AT_MOST_ONE
""" | SELECT 1 FILTER false
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_68 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_69(self):
"""
SELECT {1, 2} FILTER false
% OK %
MANY
""" | SELECT {1, 2} FILTER false
% OK %
MANY | test_edgeql_ir_card_inference_69 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_70(self):
"""
SELECT (1, 'a')
% OK %
ONE
""" | SELECT (1, 'a')
% OK %
ONE | test_edgeql_ir_card_inference_70 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_71(self):
"""
SELECT (1, Card.name)
% OK %
MANY
""" | SELECT (1, Card.name)
% OK %
MANY | test_edgeql_ir_card_inference_71 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_71b(self):
"""
SELECT ((1, Card {name}),).0
% OK %
MANY
""" | SELECT ((1, Card {name}),).0
% OK %
MANY | test_edgeql_ir_card_inference_71b | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_72(self):
"""
SELECT {a := 42}
% OK %
ONE
""" | SELECT {a := 42}
% OK %
ONE | test_edgeql_ir_card_inference_72 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_73(self):
# Make sure that a union of free shapes still ends up
# with cardinality AT_LEAST_ONE.
"""
FOR x IN {0, 1} UNION {a := x}
% OK %
AT_LEAST_ONE
""" | FOR x IN {0, 1} UNION {a := x}
% OK %
AT_LEAST_ONE | test_edgeql_ir_card_inference_73 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_74(self):
"""
SELECT taking_opt_returning_non_opt("foo")
% OK %
ONE
""" | SELECT taking_opt_returning_non_opt("foo")
% OK %
ONE | test_edgeql_ir_card_inference_74 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_75(self):
"""
SELECT taking_opt_returning_non_opt(<str>{})
% OK %
ONE
""" | SELECT taking_opt_returning_non_opt(<str>{})
% OK %
ONE | test_edgeql_ir_card_inference_75 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_76(self):
"""
SELECT taking_non_opt_returning_opt("foo")
% OK %
AT_MOST_ONE
""" | SELECT taking_non_opt_returning_opt("foo")
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_76 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_77(self):
"""
SELECT taking_non_opt_returning_opt(<str>{})
% OK %
AT_MOST_ONE
""" | SELECT taking_non_opt_returning_opt(<str>{})
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_77 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_78(self):
"""
SELECT len("foo")
% OK %
ONE
""" | SELECT len("foo")
% OK %
ONE | test_edgeql_ir_card_inference_78 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_79(self):
"""
SELECT len(<str>{})
% OK %
AT_MOST_ONE
""" | SELECT len(<str>{})
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_79 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_80(self):
"""
WITH s := {1, 2, 3}
SELECT max(s)
% OK %
ONE
""" | WITH s := {1, 2, 3}
SELECT max(s)
% OK %
ONE | test_edgeql_ir_card_inference_80 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_81(self):
"""
SELECT max(Person.p)
% OK %
AT_MOST_ONE
""" | SELECT max(Person.p)
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_81 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_82(self):
"""
SELECT assert_single(Person.p)
% OK %
AT_MOST_ONE
""" | SELECT assert_single(Person.p)
% OK %
AT_MOST_ONE | test_edgeql_ir_card_inference_82 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_83(self):
"""
SELECT Card {
element := assert_single(.element ++ "1")
}
% OK %
element: ONE
""" | SELECT Card {
element := assert_single(.element ++ "1")
}
% OK %
element: ONE | test_edgeql_ir_card_inference_83 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_84(self):
"""
SELECT array_get([1, 2, 3], {0, 2})
% OK %
MANY
""" | SELECT array_get([1, 2, 3], {0, 2})
% OK %
MANY | test_edgeql_ir_card_inference_84 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_85(self):
"""
SELECT User { optional multi m := 1 }
% OK %
m: MANY
""" | SELECT User { optional multi m := 1 }
% OK %
m: MANY | test_edgeql_ir_card_inference_85 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_86(self):
"""
SELECT User { required multi m := 1 }
% OK %
m: AT_LEAST_ONE
""" | SELECT User { required multi m := 1 }
% OK %
m: AT_LEAST_ONE | test_edgeql_ir_card_inference_86 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_87(self):
"""
SELECT User { optional m := 1 }
% OK %
m: AT_MOST_ONE
""" | SELECT User { optional m := 1 }
% OK %
m: AT_MOST_ONE | test_edgeql_ir_card_inference_87 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_88(self):
"""
SELECT User { m := assert_distinct(1) }
% OK %
m: ONE
""" | SELECT User { m := assert_distinct(1) }
% OK %
m: ONE | test_edgeql_ir_card_inference_88 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
def test_edgeql_ir_card_inference_89(self):
"""
SELECT User { m := assert_distinct(Card) }
% OK %
m: MANY
""" | SELECT User { m := assert_distinct(Card) }
% OK %
m: MANY | test_edgeql_ir_card_inference_89 | python | geldata/gel | tests/test_edgeql_ir_card_inference.py | https://github.com/geldata/gel/blob/master/tests/test_edgeql_ir_card_inference.py | Apache-2.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.