@cparra/apex-reflection 1.10.3 → 2.0.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -151,9 +151,9 @@ describe('Class reflection', () => {
151
151
  `;
152
152
  const result = (reflect(classBody)).typeMirror as ClassMirror;
153
153
  expect(result.properties.length).toBe(2);
154
- expect(result.properties[0].type).toBe('String');
154
+ expect(result.properties[0].typeReference.type).toBe('String');
155
155
  expect(result.properties[0].name).toBe('Prop1');
156
- expect(result.properties[1].type).toBe('Integer');
156
+ expect(result.properties[1].typeReference.type).toBe('Integer');
157
157
  expect(result.properties[1].name).toBe('Prop2');
158
158
  });
159
159
 
@@ -165,8 +165,8 @@ describe('Class reflection', () => {
165
165
  `;
166
166
  const result = (reflect(classBody)).typeMirror as ClassMirror;
167
167
  expect(result.fields.length).toBe(2);
168
- expect(result.fields[0].type).toBe('String');
169
- expect(result.fields[1].type).toBe('String');
168
+ expect(result.fields[0].typeReference.type).toBe('String');
169
+ expect(result.fields[1].typeReference.type).toBe('String');
170
170
  expect(result.fields[0].name).toBe('var1');
171
171
  expect(result.fields[1].name).toBe('var2');
172
172
  });
@@ -179,7 +179,7 @@ describe('Class reflection', () => {
179
179
  `;
180
180
  const result = (reflect(classBody)).typeMirror as ClassMirror;
181
181
  expect(result.fields.length).toBe(1);
182
- expect(result.fields[0].type).toBe('String');
182
+ expect(result.fields[0].typeReference.type).toBe('String');
183
183
  expect(result.fields[0].name).toBe('var1');
184
184
  expect(result.fields[0].memberModifiers).toContain('transient');
185
185
  });
@@ -244,12 +244,12 @@ describe('Class reflection', () => {
244
244
  expect(result.methods[0].memberModifiers.length).toBe(1);
245
245
  expect(result.methods[0].memberModifiers[0]).toBe('static');
246
246
  expect(result.methods[0].access_modifier).toBe('public');
247
- expect(result.methods[0].type).toBe('String');
247
+ expect(result.methods[0].typeReference.type).toBe('String');
248
248
  expect(result.methods[0].name).toBe('method1');
249
249
 
250
250
  expect(result.methods[1].memberModifiers.length).toBe(0);
251
251
  expect(result.methods[1].access_modifier).toBe('private');
252
- expect(result.methods[1].type).toBe('void');
252
+ expect(result.methods[1].typeReference.type).toBe('void');
253
253
  expect(result.methods[1].name).toBe('method2');
254
254
  });
255
255