1
- config_variables :
2
- - &keyFile jstests/libs/authTestsKey
3
- - &keyFileData Thiskeyisonlyforrunningthesuitewithauthenticationdontuseitinanytestsdirectly
4
- - &authOptions
5
- authenticationDatabase : local
6
- authenticationMechanism : SCRAM-SHA-256
7
- password : *keyFileData
8
- username : __system
9
-
10
1
test_kind : js_test
11
2
description : |
12
3
Run test suites with a replica set and multitenancy enabled. Simulate the mongoq behavior
13
- by overriding and injecting "$tenant" .
4
+ by overriding and injecting unsigned security token .
14
5
15
6
selector :
16
7
roots :
17
8
- jstests/core/**/*.js
18
9
exclude_with_any_tags :
10
+ # This passthrough uses the `simulate_mongoq` override, which some tests are incompatible with.
11
+ - simulate_mongoq_incompatible
19
12
# Exclude tests which use commands that aren't supported in Serverless.
20
13
- command_not_supported_in_serverless
21
14
# Theses tests expect replication is not enabled.
@@ -25,21 +18,21 @@ selector:
25
18
# Server side javascript (such as $where, $function, $accumulator and map-reduce) is not allowed in Serverless.
26
19
- requires_scripting
27
20
- uses_map_reduce_with_temp_collections
28
- # This test suite creates connection with user "__system", so cannot be authenticated again with different user .
21
+ # Skip any tests that run with auth explicitly .
29
22
- requires_auth
30
23
# Sharding commands are not tenant aware.
31
24
- requires_sharding
32
25
# Columnstore indexes are under development and cannot be used without enabling the feature flag
33
26
- featureFlagColumnstoreIndexes
34
27
exclude_files :
35
- # The "exhaust" function does not use runCommand (required by the inject_security_token .js override).
28
+ # The "exhaust" function does not use runCommand (required by the simulate_mongoq .js override).
36
29
- jstests/core/**/exhaust.js
37
- # These following tests use benchRun which does not use runCommand (required by the inject_dollar_tenant .js override).
30
+ # These following tests use benchRun which does not use runCommand (required by the simulate_mongoq .js override).
38
31
- jstests/core/**/bench_test1.js
39
32
- jstests/core/**/bench_test2.js
40
33
- jstests/core/**/benchrun_cmd_param_error.js
41
34
- jstests/core/**/benchrun_pipeline_updates.js
42
- # These tests run "applyOps" command which does not depend on $tenant to pass in tenant information.
35
+ # These tests run "applyOps" command which does not depend on unsigned security token pass in tenant information.
43
36
# The tenantId is provided in the oplog entries provided to the applyOps command.
44
37
- jstests/core/**/apply_ops*.js
45
38
- jstests/core/**/bypass_doc_validation.js
@@ -58,8 +51,6 @@ selector:
58
51
- jstests/core/views/view_with_invalid_dbname.js
59
52
- jstests/core/views/views_all_commands.js
60
53
- jstests/core/views/invalid_view_prevents_creating_new_view.js
61
- # This test expects a specific error message, which does not match the error message generated in authentication mode.
62
- - jstests/core/**/commands_with_uuid.js
63
54
# Sharding command "splictVector" is not tenant aware.
64
55
- jstests/core/**/splitvector.js
65
56
# Sharding command "_shardsvrCreateGlobalIndex" is not tenant aware.
@@ -75,7 +66,7 @@ selector:
75
66
# In a multitenancy environment the catalog will always return tenant-prefixed entries, so the
76
67
# list_catalog test will be broken as it checks for non-tenant-prefixed entries.
77
68
- jstests/core/**/list_catalog.js
78
- # These tests create a new thread, so $tenant won't be properly injected.
69
+ # These tests create a new thread, so unsigned security token won't be properly injected.
79
70
- jstests/core/txns/transactions_block_ddl.js
80
71
- jstests/core/txns/write_conflicts_with_non_txns.js
81
72
- jstests/core/txns/kill_op_on_txn_expiry.js
@@ -85,8 +76,14 @@ selector:
85
76
# the requests causes the test to fails due to a mismatch.
86
77
- jstests/core/api//apitest_db_profile_level.js
87
78
# Queryable encryption test requires an internal connection for the keyvault that does not
88
- # inject a $tenant .
79
+ # inject a security token .
89
80
- jstests/core/queryable_encryption/**/*.js
81
+ # TODO SERVER-82748: make "configureFailPoint" support unsigned security token.
82
+ - jstests/core/administrative/profile/profile_hide_index.js
83
+ - jstests/core/failcommand_failpoint.js
84
+ - jstests/core/comment_field.js
85
+ # TODO SERVER-81009: fix VTS missing from opCtx for distinct transactions.
86
+ - jstests/core/txns/view_reads_in_transaction.js
90
87
91
88
executor :
92
89
archive :
@@ -97,48 +94,26 @@ executor:
97
94
- ValidateCollections
98
95
config :
99
96
shell_options :
100
- # In order to use $tenant, connect mongod with user "_system" which can be authenticated with ActionType::useTenant.
101
- << : *authOptions
102
97
eval : |
103
- jsTest.authenticate(db.getMongo());
104
98
globalThis.testingReplication = true;
105
- await import('jstests/libs/override_methods/inject_dollar_tenant .js');
99
+ await import('jstests/libs/override_methods/simulate_mongoq .js');
106
100
global_vars :
107
101
TestData : &TestData
108
102
tenantId : " 636d957b2646ddfaf9b5e13f"
103
+ useSignedSecurityToken : false
109
104
hashTestNamesForMultitenancy : true
110
- auth : true
111
- authMechanism : SCRAM-SHA-256
112
- keyFile : *keyFile
113
- keyFileData : *keyFileData
114
- roleGraphInvalidationIsFatal : true
115
105
hooks :
116
106
# The CheckReplDBHash hook waits until all operations have replicated to and have been applied
117
107
# on the secondaries, so we run the ValidateCollections hook after it to ensure we're
118
108
# validating the entire contents of the collection.
119
109
- class : CheckReplOplogs
120
- shell_options :
121
- global_vars :
122
- TestData : *TestData
123
- eval : jsTest.authenticate(db.getMongo())
124
- << : *authOptions
125
110
- class : CheckReplDBHash
126
- shell_options :
127
- global_vars :
128
- TestData : *TestData
129
- eval : jsTest.authenticate(db.getMongo())
130
- << : *authOptions
131
111
- class : ValidateCollections
132
- shell_options :
133
- global_vars :
134
- TestData : *TestData
135
- eval : jsTest.authenticate(db.getMongo())
136
- << : *authOptions
137
112
- class : CleanEveryN
138
113
n : 20
139
114
fixture :
140
115
class : ReplicaSetFixture
141
- num_nodes : 3
116
+ num_nodes : 2
142
117
mongod_options :
143
118
set_parameters :
144
119
enableTestCommands : 1
@@ -147,7 +122,4 @@ executor:
147
122
featureFlagRequireTenantID : true
148
123
logComponentVerbosity :
149
124
command : 2
150
- auth : ' '
151
- keyFile : *keyFile
152
125
noscripting : ' '
153
- auth_options : *authOptions
0 commit comments