@@ -207,6 +207,40 @@ void testFullMdclasses(ArgumentsAccessor argumentsAccessor) {
207
207
.isEmpty ();
208
208
}
209
209
210
+ @ ParameterizedTest
211
+ @ CsvSource (
212
+ {
213
+ "false, mdclasses_ext" ,
214
+ }
215
+ )
216
+ void testFullExt (ArgumentsAccessor argumentsAccessor ) {
217
+ var mdc = MDTestUtils .readConfiguration (argumentsAccessor , false );
218
+ assertThat (mdc ).isInstanceOf (ConfigurationExtension .class );
219
+ var cf = (ConfigurationExtension ) mdc ;
220
+ assertThat (cf .getSupportVariant ()).isEqualTo (SupportVariant .NONE );
221
+ assertThat (cf .getModules ()).isEmpty ();
222
+ assertThat (cf .getAllModules ())
223
+ .hasSize (7 + cf .getCommonModules ().size ())
224
+ .allMatch (module -> module .getSupportVariant ().equals (SupportVariant .NONE ));
225
+
226
+ // проверка состава дочерних
227
+ checkChildrenExt (cf );
228
+
229
+ assertThat (cf .getPlainChildren ())
230
+ .hasSize (147 )
231
+ .allMatch (md -> md .getSupportVariant ().equals (SupportVariant .NONE ));
232
+
233
+ assertThat (cf .getAllModules ().stream ().filter (Module ::isProtected )).isEmpty ();
234
+
235
+ assertThat (cf .getChildren ().stream ().filter (md -> md instanceof Form form && !form .getData ().isEmpty ()))
236
+ .hasSize (cf .getCommonForms ().size ());
237
+ assertThat (cf .getPlainChildren ().stream ().filter (md -> md instanceof Form form && !form .getData ().isEmpty ()))
238
+ .hasSize (cf .getCommonForms ().size () + 12 );
239
+ assertThat (cf .getPlainChildren ().stream ().filter (md -> md instanceof Form form && form .getData ().isEmpty ()))
240
+ .isEmpty ();
241
+ }
242
+
243
+
210
244
private static void checkChildrenSSL (Configuration cf ) {
211
245
assertThat (cf .getSubsystems ())
212
246
.hasSize (3 )
@@ -626,4 +660,212 @@ private static void checkChildrenMdclasses(Configuration cf) {
626
660
cf .getExternalDataSources ().size ());
627
661
}
628
662
663
+ private static void checkChildrenExt (ConfigurationExtension cf ) {
664
+ assertThat (cf .getSubsystems ())
665
+ .hasSize (2 )
666
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
667
+
668
+ assertThat (cf .getCommonModules ())
669
+ .hasSize (9 )
670
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
671
+
672
+ assertThat (cf .getSessionParameters ())
673
+ .hasSize (2 )
674
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
675
+
676
+ assertThat (cf .getRoles ())
677
+ .hasSize (2 )
678
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
679
+
680
+ assertThat (cf .getCommonAttributes ())
681
+ .hasSize (1 )
682
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
683
+
684
+ assertThat (cf .getExchangePlans ())
685
+ .hasSize (2 )
686
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
687
+
688
+ assertThat (cf .getFilterCriteria ())
689
+ .hasSize (2 )
690
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
691
+
692
+ assertThat (cf .getEventSubscriptions ())
693
+ .hasSize (1 )
694
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
695
+
696
+ assertThat (cf .getScheduledJobs ())
697
+ .hasSize (1 )
698
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
699
+
700
+ assertThat (cf .getBots ()).isEmpty ();
701
+
702
+ assertThat (cf .getFunctionalOptions ())
703
+ .hasSize (2 )
704
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
705
+
706
+ assertThat (cf .getFunctionalOptionsParameters ())
707
+ .hasSize (2 )
708
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
709
+
710
+ assertThat (cf .getDefinedTypes ())
711
+ .hasSize (1 )
712
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
713
+
714
+ assertThat (cf .getSettingsStorages ())
715
+ .hasSize (1 )
716
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
717
+
718
+ assertThat (cf .getCommonForms ())
719
+ .hasSize (2 )
720
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
721
+
722
+ assertThat (cf .getCommonCommands ())
723
+ .hasSize (2 )
724
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
725
+
726
+ assertThat (cf .getCommandGroups ())
727
+ .hasSize (2 )
728
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
729
+
730
+ assertThat (cf .getCommonTemplates ())
731
+ .hasSize (2 )
732
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
733
+
734
+ assertThat (cf .getCommonPictures ())
735
+ .hasSize (2 )
736
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
737
+
738
+ assertThat (cf .getInterfaces ()).isEmpty ();
739
+
740
+ assertThat (cf .getXDTOPackages ())
741
+ .hasSize (2 )
742
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
743
+
744
+ assertThat (cf .getWebServices ())
745
+ .hasSize (2 )
746
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
747
+
748
+ assertThat (cf .getHttpServices ())
749
+ .hasSize (2 )
750
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
751
+
752
+ assertThat (cf .getWsReferences ())
753
+ .hasSize (2 )
754
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
755
+
756
+ assertThat (cf .getIntegrationServices ()).isEmpty ();
757
+
758
+ assertThat (cf .getStyleItems ())
759
+ .hasSize (2 )
760
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
761
+
762
+ assertThat (cf .getStyles ())
763
+ .hasSize (2 )
764
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
765
+
766
+ assertThat (cf .getLanguages ())
767
+ .hasSize (1 )
768
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
769
+
770
+ assertThat (cf .getConstants ())
771
+ .hasSize (2 )
772
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
773
+
774
+ assertThat (cf .getCatalogs ())
775
+ .hasSize (2 )
776
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
777
+
778
+ assertThat (cf .getDocuments ())
779
+ .hasSize (2 )
780
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
781
+
782
+ assertThat (cf .getDocumentNumerators ())
783
+ .hasSize (1 )
784
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
785
+
786
+ assertThat (cf .getSequences ())
787
+ .hasSize (1 )
788
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
789
+
790
+ assertThat (cf .getDocumentJournals ())
791
+ .hasSize (1 )
792
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
793
+
794
+ assertThat (cf .getEnums ())
795
+ .hasSize (2 )
796
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
797
+
798
+ assertThat (cf .getReports ())
799
+ .hasSize (2 )
800
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
801
+
802
+ assertThat (cf .getDataProcessors ())
803
+ .hasSize (2 )
804
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
805
+
806
+ assertThat (cf .getChartsOfCharacteristicTypes ())
807
+ .hasSize (2 )
808
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
809
+
810
+ assertThat (cf .getChartsOfAccounts ())
811
+ .hasSize (2 )
812
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
813
+
814
+ assertThat (cf .getChartsOfCalculationTypes ())
815
+ .hasSize (2 )
816
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
817
+
818
+ assertThat (cf .getInformationRegisters ())
819
+ .hasSize (4 )
820
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
821
+
822
+ assertThat (cf .getAccumulationRegisters ())
823
+ .hasSize (2 )
824
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
825
+
826
+ assertThat (cf .getAccountingRegisters ())
827
+ .hasSize (2 )
828
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
829
+
830
+ assertThat (cf .getCalculationRegisters ())
831
+ .hasSize (2 )
832
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
833
+
834
+ assertThat (cf .getBusinessProcesses ())
835
+ .hasSize (1 )
836
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
837
+
838
+ assertThat (cf .getTasks ())
839
+ .hasSize (1 )
840
+ .allMatch (mdo -> mdo .getSupportVariant ().equals (SupportVariant .NONE ));
841
+
842
+ assertThat (cf .getExternalDataSources ()).isEmpty ();
843
+
844
+ assertThat (cf .getChildren ()).hasSize (
845
+ cf .getSubsystems ().size () + cf .getCommonModules ().size () +
846
+ cf .getSessionParameters ().size () + cf .getRoles ().size () +
847
+ cf .getCommonAttributes ().size () + cf .getExchangePlans ().size () +
848
+ cf .getFilterCriteria ().size () + cf .getEventSubscriptions ().size () +
849
+ cf .getScheduledJobs ().size () + cf .getBots ().size () +
850
+ cf .getFunctionalOptions ().size () + cf .getFunctionalOptionsParameters ().size () +
851
+ cf .getDefinedTypes ().size () + cf .getSettingsStorages ().size () +
852
+ cf .getCommonForms ().size () + cf .getCommonCommands ().size () +
853
+ cf .getCommandGroups ().size () + cf .getCommonTemplates ().size () +
854
+ cf .getCommonPictures ().size () + cf .getInterfaces ().size () +
855
+ cf .getXDTOPackages ().size () + cf .getWebServices ().size () +
856
+ cf .getHttpServices ().size () + cf .getWsReferences ().size () +
857
+ cf .getIntegrationServices ().size () + cf .getStyleItems ().size () +
858
+ cf .getStyles ().size () + cf .getLanguages ().size () +
859
+ cf .getConstants ().size () + cf .getCatalogs ().size () +
860
+ cf .getDocuments ().size () + cf .getDocumentNumerators ().size () +
861
+ cf .getSequences ().size () + cf .getDocumentJournals ().size () +
862
+ cf .getEnums ().size () + cf .getReports ().size () +
863
+ cf .getDataProcessors ().size () + cf .getChartsOfCharacteristicTypes ().size () +
864
+ cf .getChartsOfAccounts ().size () + cf .getChartsOfCalculationTypes ().size () +
865
+ cf .getInformationRegisters ().size () + cf .getAccumulationRegisters ().size () +
866
+ cf .getAccountingRegisters ().size () + cf .getCalculationRegisters ().size () +
867
+ cf .getBusinessProcesses ().size () + cf .getTasks ().size () +
868
+ cf .getExternalDataSources ().size ());
869
+ }
870
+
629
871
}
0 commit comments