Skip to content

Commit ce91691

Browse files
authored
chore(cli): Update goldens (#261)
1 parent d4cda5f commit ce91691

File tree

25 files changed

+291
-122
lines changed

25 files changed

+291
-122
lines changed

apps/cli/fixtures/standalone/api/lib/src/generated/cloud.celest.dart

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// it can be checked into version control.
33
// ignore_for_file: type=lint, unused_local_variable, unnecessary_cast, unnecessary_import, deprecated_member_use, invalid_use_of_internal_member
44

5-
library;
5+
library; // ignore_for_file: no_leading_underscores_for_library_prefixes
66

7-
import 'package:celest/src/core/context.dart';
7+
import 'package:celest/src/core/context.dart' as _$celest;
88
import 'package:celest_backend/src/generated/config.celest.dart';
99

1010
/// The interface to your Celest backend.
@@ -16,7 +16,7 @@ const CelestCloud celest = CelestCloud._();
1616

1717
/// A per-request context object which propogates request information and common
1818
/// accessors to the Celest server environment.
19-
CelestContext get context => CelestContext._(context);
19+
CelestContext get context => CelestContext._(_$celest.context);
2020

2121
/// The interface to your Celest backend.
2222
///
@@ -42,4 +42,5 @@ class CelestCloud {
4242

4343
/// A per-request context object which propogates request information and common
4444
/// accessors to the Celest server environment.
45-
extension type CelestContext._(Context _context) implements Context {}
45+
extension type CelestContext._(_$celest.Context _context)
46+
implements _$celest.Context {}

apps/cli/fixtures/standalone/api/lib/src/generated/config.celest.dart

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@
22
// it can be checked into version control.
33
// ignore_for_file: type=lint, unused_local_variable, unnecessary_cast, unnecessary_import, deprecated_member_use, invalid_use_of_internal_member
44

5-
library;
5+
library; // ignore_for_file: no_leading_underscores_for_library_prefixes
66

7-
import 'package:celest/celest.dart';
8-
import 'package:celest/src/core/context.dart';
7+
import 'package:celest/celest.dart' as _$celest;
8+
import 'package:celest/src/core/context.dart' as _$celest;
99

1010
/// An environment of a deployed Celest service.
1111
///
1212
/// Celest services can have multiple isolated branches, for example
1313
/// a `development` and `production` environment.
1414
extension type const CelestEnvironment._(String _env)
15-
implements Environment, String {
15+
implements _$celest.Environment, String {
1616
/// The local Celest environment, used to delineate when a
1717
/// Celest service is running on a developer machine as opposed
1818
/// to the cloud.
@@ -41,5 +41,6 @@ class CelestVariables {
4141
///
4242
/// This is set by the deployment environment and is used to
4343
/// determine the current environment of the Celest service.
44-
String get currentEnvironment => context.expect(env.environment);
44+
String get currentEnvironment =>
45+
_$celest.context.expect(_$celest.env.environment);
4546
}

apps/cli/fixtures/standalone/auth/client/lib/auth_client.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ class Celest with _$celest.CelestBase {
8282
}
8383
_currentEnvironment = environment;
8484
_baseUri = environment.baseUri;
85-
scheduleMicrotask(_auth.init);
85+
scheduleMicrotask(() => _auth.init());
8686
if (!_initialized) {
8787
initSerializers(serializers: serializers);
8888
}

apps/cli/fixtures/standalone/auth/goldens/ast.resolved.json

Lines changed: 78 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/cli/fixtures/standalone/auth/goldens/celest.json

Lines changed: 67 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/cli/fixtures/standalone/auth/lib/src/generated/auth.celest.dart

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
// it can be checked into version control.
33
// ignore_for_file: type=lint, unused_local_variable, unnecessary_cast, unnecessary_import, deprecated_member_use, invalid_use_of_internal_member
44

5-
library;
5+
library; // ignore_for_file: no_leading_underscores_for_library_prefixes
66

7-
import 'package:celest/celest.dart';
8-
import 'package:celest/src/core/context.dart';
9-
import 'package:celest/src/runtime/data/connect.dart';
10-
import 'package:celest_cloud_auth/celest_cloud_auth.dart';
7+
import 'package:celest/celest.dart' as _$celest;
8+
import 'package:celest/src/core/context.dart' as _$celest;
9+
import 'package:celest/src/runtime/data/connect.dart' as _$celest;
10+
import 'package:celest_cloud_auth/celest_cloud_auth.dart' as _$celest;
1111

1212
/// The auth service for the Celest backend.
1313
///
@@ -17,21 +17,21 @@ class CelestAuth {
1717
const CelestAuth();
1818

1919
/// Initializes the Celest Auth service in the given [context].
20-
static Future<void> init(Context context) async {
21-
final database = await connect(
20+
static Future<void> init(_$celest.Context context) async {
21+
final database = await _$celest.connect(
2222
context,
2323
name: 'CelestAuthDatabase',
24-
factory: AuthDatabase.new,
25-
hostnameVariable: const env('CELEST_AUTH_DATABASE_HOST'),
26-
tokenSecret: const secret('CELEST_AUTH_DATABASE_TOKEN'),
24+
factory: _$celest.AuthDatabase.new,
25+
hostnameVariable: const _$celest.env('CELEST_AUTH_DATABASE_HOST'),
26+
tokenSecret: const _$celest.secret('CELEST_AUTH_DATABASE_TOKEN'),
2727
);
28-
final service = await CelestCloudAuth.create(database: database);
28+
final service = await _$celest.CelestCloudAuth.create(database: database);
2929
context.router.mount(
3030
'/v1alpha1/auth/',
3131
service.handler,
3232
);
3333
context.put(
34-
CelestCloudAuth.contextKey,
34+
_$celest.CelestCloudAuth.contextKey,
3535
service,
3636
);
3737
}

apps/cli/fixtures/standalone/auth/lib/src/generated/cloud.celest.dart

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// it can be checked into version control.
33
// ignore_for_file: type=lint, unused_local_variable, unnecessary_cast, unnecessary_import, deprecated_member_use, invalid_use_of_internal_member
44

5-
library;
5+
library; // ignore_for_file: no_leading_underscores_for_library_prefixes
66

7-
import 'package:celest/src/core/context.dart';
7+
import 'package:celest/src/core/context.dart' as _$celest;
88
import 'package:celest_backend/src/generated/config.celest.dart';
99

1010
/// The interface to your Celest backend.
@@ -16,7 +16,7 @@ const CelestCloud celest = CelestCloud._();
1616

1717
/// A per-request context object which propogates request information and common
1818
/// accessors to the Celest server environment.
19-
CelestContext get context => CelestContext._(context);
19+
CelestContext get context => CelestContext._(_$celest.context);
2020

2121
/// The interface to your Celest backend.
2222
///
@@ -42,4 +42,5 @@ class CelestCloud {
4242

4343
/// A per-request context object which propogates request information and common
4444
/// accessors to the Celest server environment.
45-
extension type CelestContext._(Context _context) implements Context {}
45+
extension type CelestContext._(_$celest.Context _context)
46+
implements _$celest.Context {}

apps/cli/fixtures/standalone/auth/lib/src/generated/config.celest.dart

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@
22
// it can be checked into version control.
33
// ignore_for_file: type=lint, unused_local_variable, unnecessary_cast, unnecessary_import, deprecated_member_use, invalid_use_of_internal_member
44

5-
library;
5+
library; // ignore_for_file: no_leading_underscores_for_library_prefixes
66

7-
import 'package:celest/celest.dart';
8-
import 'package:celest/src/core/context.dart';
7+
import 'package:celest/celest.dart' as _$celest;
8+
import 'package:celest/src/core/context.dart' as _$celest;
99

1010
/// An environment of a deployed Celest service.
1111
///
1212
/// Celest services can have multiple isolated branches, for example
1313
/// a `development` and `production` environment.
1414
extension type const CelestEnvironment._(String _env)
15-
implements Environment, String {
15+
implements _$celest.Environment, String {
1616
/// The local Celest environment, used to delineate when a
1717
/// Celest service is running on a developer machine as opposed
1818
/// to the cloud.
@@ -41,5 +41,6 @@ class CelestVariables {
4141
///
4242
/// This is set by the deployment environment and is used to
4343
/// determine the current environment of the Celest service.
44-
String get currentEnvironment => context.expect(env.environment);
44+
String get currentEnvironment =>
45+
_$celest.context.expect(_$celest.env.environment);
4546
}

apps/cli/fixtures/standalone/data/lib/src/generated/cloud.celest.dart

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// it can be checked into version control.
33
// ignore_for_file: type=lint, unused_local_variable, unnecessary_cast, unnecessary_import, deprecated_member_use, invalid_use_of_internal_member
44

5-
library;
5+
library; // ignore_for_file: no_leading_underscores_for_library_prefixes
66

7-
import 'package:celest/src/core/context.dart';
7+
import 'package:celest/src/core/context.dart' as _$celest;
88
import 'package:celest_backend/src/generated/config.celest.dart';
99
import 'package:celest_backend/src/generated/data.celest.dart';
1010

@@ -17,7 +17,7 @@ const CelestCloud celest = CelestCloud._();
1717

1818
/// A per-request context object which propogates request information and common
1919
/// accessors to the Celest server environment.
20-
CelestContext get context => CelestContext._(context);
20+
CelestContext get context => CelestContext._(_$celest.context);
2121

2222
/// The interface to your Celest backend.
2323
///
@@ -49,4 +49,5 @@ class CelestCloud {
4949

5050
/// A per-request context object which propogates request information and common
5151
/// accessors to the Celest server environment.
52-
extension type CelestContext._(Context _context) implements Context {}
52+
extension type CelestContext._(_$celest.Context _context)
53+
implements _$celest.Context {}

apps/cli/fixtures/standalone/data/lib/src/generated/config.celest.dart

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@
22
// it can be checked into version control.
33
// ignore_for_file: type=lint, unused_local_variable, unnecessary_cast, unnecessary_import, deprecated_member_use, invalid_use_of_internal_member
44

5-
library;
5+
library; // ignore_for_file: no_leading_underscores_for_library_prefixes
66

7-
import 'package:celest/celest.dart';
8-
import 'package:celest/src/core/context.dart';
7+
import 'package:celest/celest.dart' as _$celest;
8+
import 'package:celest/src/core/context.dart' as _$celest;
99

1010
/// An environment of a deployed Celest service.
1111
///
1212
/// Celest services can have multiple isolated branches, for example
1313
/// a `development` and `production` environment.
1414
extension type const CelestEnvironment._(String _env)
15-
implements Environment, String {
15+
implements _$celest.Environment, String {
1616
/// The local Celest environment, used to delineate when a
1717
/// Celest service is running on a developer machine as opposed
1818
/// to the cloud.
@@ -41,5 +41,6 @@ class CelestVariables {
4141
///
4242
/// This is set by the deployment environment and is used to
4343
/// determine the current environment of the Celest service.
44-
String get currentEnvironment => context.expect(env.environment);
44+
String get currentEnvironment =>
45+
_$celest.context.expect(_$celest.env.environment);
4546
}

0 commit comments

Comments
 (0)