Test tenant bootstrap – system description

The steps of the test bootstrap on the regular operating paths, idempotency, the state query and the super-administrator-only access.

Overview

Builds a test tenant from scratch on the regular operating paths (company model, Dlbtclient, Dlbtprovision), without own SQL, idempotently. Table names carry the installation's own prefix in the database.

Run steps (bootstrap.run)

  1. Company group by name.
  2. Client company: searched by exact name, otherwise addCompany; NAV row.
  3. User in the given user group; attachUserToClient; check of the content scope.
  4. Subscription: with an existing open one the period is activated (activateSubscriptionPeriod), otherwise a new active subscription (addActiveClientSubscription).
  5. syncClientPlan().

bootstrap.state returns the state and limits (Dlbtclient::limits) of the client found by tax number prefix. Data touched: company_group, company, base user table, subscription_account, subscription, user_feature.

Permissions

In the seed bootstrap::list and bootstrap::run are SYSTEM, but the controller does not ask for them: every endpoint requires isSuper(), and the menu item is shown to the super administrator only.

Related topics: tenant permissions