mirror of
https://github.com/appwrite/appwrite.git
synced 2026-11-18 20:36:03 +00:00
test: isolate execution deployment identity from shared fixtures
This commit is contained in:
1 parent
7c856a5889
commit
82adc02389
1 file changed
+19
-1
@@ -1972,7 +1972,25 @@ final class FunctionsCustomServerTest extends Scope
|
||||
|
||||
public function testCreateExecution(): void
|
||||
{
|
||||
$data = $this->setupTestDeployment();
|
||||
// Other deployment tests can replace the cached function's active build.
|
||||
// Own the function here so the execution identity has a stable target.
|
||||
$functionId = $this->setupFunction([
|
||||
'functionId' => ID::unique(),
|
||||
'name' => 'Test1',
|
||||
'runtime' => 'node-22',
|
||||
'entrypoint' => 'index.js',
|
||||
'timeout' => 15,
|
||||
]);
|
||||
$variable = $this->createVariable($functionId, [
|
||||
'key' => 'GLOBAL_VARIABLE',
|
||||
'value' => 'Global Variable Value',
|
||||
]);
|
||||
$this->assertEquals(201, $variable['headers']['status-code']);
|
||||
$deploymentId = $this->setupDeployment($functionId, [
|
||||
'code' => $this->packageFunction('basic'),
|
||||
'activate' => true,
|
||||
]);
|
||||
$data = ['functionId' => $functionId, 'deploymentId' => $deploymentId];
|
||||
|
||||
/**
|
||||
* Test for SUCCESS
|
||||
|
||||
Reference in new issue
Block a user