Preserve VLESS WebSocket variants during subscription refresh
This commit is contained in:
@@ -13,6 +13,7 @@ import {
|
||||
} from '../../dist/shared/contracts/state.js';
|
||||
import { createServerId } from '../../dist/shared/serverIdentity.js';
|
||||
import { HARBOR_VERSIONS } from '../../dist/shared/versions.js';
|
||||
import { normalizeSubscriptionConfig } from '../../dist/server/subscription.js';
|
||||
|
||||
const root = path.resolve(import.meta.dirname, '../..');
|
||||
|
||||
@@ -154,10 +155,13 @@ test('data invariant: API mutations return one snapshot, increase revision and r
|
||||
server: 'vpn.example.test',
|
||||
server_port: 443,
|
||||
uuid: '00000000-0000-4000-8000-000000000000',
|
||||
tls: { enabled: true },
|
||||
tls: { enabled: true, server_name: 'edge.example.test' },
|
||||
transport: { type: 'ws', path: '/test', headers: { Host: 'edge.example.test' } },
|
||||
}],
|
||||
};
|
||||
const testServerId = createServerId(config.outbounds[0]);
|
||||
const legacyServerId = createServerId(config.outbounds[0]);
|
||||
const testServerId = normalizeSubscriptionConfig(config).servers[0].id;
|
||||
assert.notEqual(testServerId, legacyServerId);
|
||||
fs.mkdirSync(binDir);
|
||||
const singboxPath = path.join(binDir, 'sing-box');
|
||||
const workingSingbox = `#!/usr/bin/env node
|
||||
|
||||
Reference in New Issue
Block a user