testFixtures

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Replaced `ComponentSpecInternal` with a more specific internal interface that represents a component that is built into some intermediate format before its final outputs are produced.

This new interface is internal as it is essentially just a rename of `ComponentSpecInternal`, and will probably be replaced by something instead based on the target platform(s) of the component.

  1. … 17 more files in changeset.
Removed unused lvar.

Removed the notion of a language registration, as it is not required.

This was previously implied by a language source set type registration, but the definition of the language is no longer used anywhere.

This will allow the language name to be removed from the language source set type registration. It is still present, but now unused.

  1. … 4 more files in changeset.
Fixed broken unit test.

Use types in StructBindingsStore API

+review REVIEW-5761

  1. … 8 more files in changeset.
Pass struct bindings all the way

Instead of passing the delegate type in raw format, pass the struct

bindings from node initializer down to proxy generator.

+review REVIEW-5761

  1. … 25 more files in changeset.
LanguageRegistry is not needed anymore, remove it

LanguageSourceSetFactory now holds all the LanguageRegistrations.

+review REVIEW-5734

  1. … 3 more files in changeset.
Moved registration of `BinarySpec.tasks` from `BinaryBasePlugin` to `BaseBinarySpec`.

Also use the descriptor of a `BinarySpec` or `ComponentSpec` as the descriptor for its children, consistent with the approach used for the children of a struct.

  1. … 15 more files in changeset.
Fixed broken unit tests that expect the tasks for a binary to be defined.

Moved some rules from `ComponentBasePlugin` to `BinaryBasePlugin` so that it can be applied without error.

Added some unit test coverage for `BinaryBasePlugin`.

  1. … 4 more files in changeset.
Split `BinaryBasePlugin` out of `LanguageBasePlugin`.

  1. … 7 more files in changeset.
Extracted a base specification which can be used for writing software model plugin unit tests, from various existing unit tests.

  1. … 4 more files in changeset.
Manage creation of most PatternSet instances

- use managed CachingPatternSpecFactory instance for

these PatternSet instances

+review REVIEW-5627

  1. … 37 more files in changeset.
Moved a bunch of singletons off several prod classes to live on `ProjectRegistrySpec`.

+review REVIEW-5756

  1. … 30 more files in changeset.
Merge LanguageRegistry into LanguageSourceSetFactory

Introduce `LanguageRegistry getRegistrations()` in

`LanguageSourceSetFactory`.

Get rid of `languages` node and rules that used to propagate

language registrations to `LanguageSourceSetFactory`.

Along the way, `LanguageRegistration` used in `LanguageRegistry` has

been reduced to only contains necessary data.

It no longer needs the data used for factory registration.

Other changes are impacts, mostly in tests.

+review REVIEW-5734

  1. … 10 more files in changeset.
Simplify ModelRegistrations

Make the purpose of actions added during registration a bit cleaner,

too.

+review REVIEW-5738

  1. … 7 more files in changeset.
Rework extensible type fixtures to simplify code

+review REVIEW-5695

  1. … 11 more files in changeset.
Make extensible type fixtures work with managed types

Things that had to be cleared up:

- not all Base*Fixtures classes were creating nodes with managed

projections

- some tests were using a separate ManagedProxyFactory, and the same

type got generated twice in the same classloader

+review REVIEW-5695

  1. … 14 more files in changeset.
Fixed `BaseLanguageSourceSetFixture` so that it returns a view of the source set with all the DSL magic mixed in, rather than the base implementation.

+review REVIEW-5708

Fixed some merge problems.

+review REVIEW-5708

  1. … 6 more files in changeset.
Do not use the legacy decoration on the delegate objects created for `ComponentSpec`, `BinarySpec` and `LanguageSourceSet` elements.

+review REVIEW-5708

  1. … 25 more files in changeset.
Minor edits polishing changes made while CompSpec managed work

- various renames, among them overriden -> overridden

- remove now spurious files

- opportunistically remove useless printlns in tests

- fix some groovy warning in tests

+review REVIEW-5695

  1. … 8 more files in changeset.
No need to track implicit dependencies

We weren’t really using this feature, either, just passing empty lists

(or even nulls) around, and never using them.

  1. … 15 more files in changeset.
Introduce node backed protected BaseBinarySpec.getComponentAs(type)

Binaries are owned by a Component. NativeComponentSpec expose it via its

`getComponent` method. This method is then overriden by subtypes to

specialize its return type.

BaseBinarySpec store a direct reference to some ComponentSpecInternal in

its `owner` field and its `getComponent` method basically returns it.

Specialized versions of this method presents in subtypes simply cast

`owner`. This ComponentSpecInternal happens to be the `privateData` of

the backing node which can't be cast to the corresponding managed public

type (eg. CUnitTSS, GoogleTestTSS).

This commit starts in BaseBinarySpec:

- replace the `owner` field by a `componentNode`

- introduce protected getComponentAs(type) with relies on

`node.asImmutable(type)` insted of casting

With theses changes, a `BinarySpec` can be owned by a

`@Managed ComponentSpec`.

BaseBinarySpec creation now use a node instead of a

ComponentSpecInternal to refer to its owner component. This explain the

impact on fixtures and tests.

Removed spurious specialized getComponent() methods in NativeBinarySpec

subtypes along the way.

+review REVIEW-5695

  1. … 19 more files in changeset.
Move ModelRegistryHelper functionality to Groovy extension module

+review REVIEW-5715

  1. … 19 more files in changeset.
Use the public type of a `LanguageSourceSet` in its display name.

+review REVIEW-5708

  1. … 20 more files in changeset.
Use a consistent `toString()` and `displayName` for all ComponentSpec views, regardless of whether the view is `@Managed` or not.

Four parts to this change:

1. Shuffled around the API of `InstanceFactory` so that there is less difference between elements with `@Managed` and unmanaged public types from a consumer's perspective.

2. Changed the API of `InstanceFactory` so that factories are presented with the public type of the element.

3. Changed how `BaseComponentSpec` instances are created so that thier public type is used in there display name.

4. Changed view generation so that `toString()` implementation will use the delegate's display name, if present.

+review REVIEW-5708

  1. … 18 more files in changeset.
Use `ModelType` instead of `Class` in `LanguageRegistration`

  1. … 10 more files in changeset.
Introduce convenience methods on ModelRegistry

+review REVIEW-5685

  1. … 24 more files in changeset.
BaseBinarySpec.sources is a node-backed ModelMap

  1. … 22 more files in changeset.