How to use ignore method in Webdriverio

Best JavaScript code snippet using webdriverio-monorepo

modularize.js

Source:modularize.js Github

copy

Full Screen

1/**2 * @author mrdoob / http://mrdoob.com/3 * @author Mugen87 / https://github.com/Mugen874 */5var fs = require( 'fs' );6THREE = require( '../build/three.js' );7var srcFolder = __dirname + '/../examples/js/';8var dstFolder = __dirname + '/../examples/jsm/';9var files = [10 { path: 'animation/AnimationClipCreator.js', dependencies: [], ignoreList: [] },11 { path: 'animation/CCDIKSolver.js', dependencies: [], ignoreList: [ 'SkinnedMesh' ] },12 { path: 'animation/MMDAnimationHelper.js', dependencies: [ { name: 'CCDIKSolver', path: 'animation/CCDIKSolver.js' }, { name: 'MMDPhysics', path: 'animation/MMDPhysics.js' } ], ignoreList: [ 'AnimationClip', 'Audio', 'Camera', 'SkinnedMesh' ] },13 { path: 'animation/MMDPhysics.js', dependencies: [], ignoreList: [ 'SkinnedMesh' ] },14 { path: 'animation/TimelinerController.js', dependencies: [], ignoreList: [] },15 { path: 'cameras/CinematicCamera.js', dependencies: [ { name: 'BokehShader', path: 'shaders/BokehShader2.js' }, { name: 'BokehDepthShader', path: 'shaders/BokehShader2.js' } ], ignoreList: [] },16 { path: 'controls/DragControls.js', dependencies: [], ignoreList: [] },17 { path: 'controls/DeviceOrientationControls.js', dependencies: [], ignoreList: [] },18 { path: 'controls/FirstPersonControls.js', dependencies: [], ignoreList: [] },19 { path: 'controls/FlyControls.js', dependencies: [], ignoreList: [] },20 { path: 'controls/OrbitControls.js', dependencies: [], ignoreList: [] },21 { path: 'controls/PointerLockControls.js', dependencies: [], ignoreList: [] },22 { path: 'controls/TrackballControls.js', dependencies: [], ignoreList: [] },23 { path: 'controls/TransformControls.js', dependencies: [], ignoreList: [] },24 { path: 'curves/CurveExtras.js', dependencies: [], ignoreList: [] },25 { path: 'curves/NURBSCurve.js', dependencies: [ { name: 'NURBSUtils', path: 'curves/NURBSUtils.js' } ], ignoreList: [] },26 { path: 'curves/NURBSSurface.js', dependencies: [ { name: 'NURBSUtils', path: 'curves/NURBSUtils.js' } ], ignoreList: [] },27 { path: 'curves/NURBSUtils.js', dependencies: [], ignoreList: [] },28 { path: 'effects/AnaglyphEffect.js', dependencies: [], ignoreList: [] },29 { path: 'effects/AsciiEffect.js', dependencies: [], ignoreList: [] },30 { path: 'effects/OutlineEffect.js', dependencies: [], ignoreList: [] },31 { path: 'effects/ParallaxBarrierEffect.js', dependencies: [], ignoreList: [] },32 { path: 'effects/PeppersGhostEffect.js', dependencies: [], ignoreList: [] },33 { path: 'effects/StereoEffect.js', dependencies: [], ignoreList: [] },34 { path: 'exporters/ColladaExporter.js', dependencies: [], ignoreList: [] },35 { path: 'exporters/DRACOExporter.js', dependencies: [], ignoreList: [ 'Geometry' ] },36 { path: 'exporters/GLTFExporter.js', dependencies: [], ignoreList: [ 'AnimationClip', 'Camera', 'Geometry', 'Material', 'Mesh', 'Object3D', 'RGBFormat', 'Scenes', 'ShaderMaterial', 'VertexColors' ] },37 { path: 'exporters/MMDExporter.js', dependencies: [ { name: 'MMDParser', path: 'libs/mmdparser.module.js' } ], ignoreList: [] },38 { path: 'exporters/OBJExporter.js', dependencies: [], ignoreList: [] },39 { path: 'exporters/PLYExporter.js', dependencies: [], ignoreList: [] },40 { path: 'exporters/STLExporter.js', dependencies: [], ignoreList: [] },41 { path: 'exporters/TypedGeometryExporter.js', dependencies: [], ignoreList: [] },42 { path: 'geometries/BoxLineGeometry.js', dependencies: [], ignoreList: [] },43 { path: 'geometries/ConvexGeometry.js', dependencies: [ { name: 'ConvexHull', path: 'math/ConvexHull.js' } ], ignoreList: [] },44 { path: 'geometries/DecalGeometry.js', dependencies: [], ignoreList: [] },45 { path: 'geometries/LightningStrike.js', dependencies: [ { name: 'SimplexNoise', path: 'math/SimplexNoise.js' } ], ignoreList: [ 'Mesh' ] },46 { path: 'geometries/ParametricGeometries.js', dependencies: [], ignoreList: [] },47 { path: 'geometries/TeapotBufferGeometry.js', dependencies: [], ignoreList: [] },48 { path: 'interactive/SelectionBox.js', dependencies: [], ignoreList: [] },49 { path: 'interactive/SelectionHelper.js', dependencies: [], ignoreList: [] },50 { path: 'lights/LightProbeGenerator.js', dependencies: [], ignoreList: [] },51 { path: 'lights/RectAreaLightUniformsLib.js', dependencies: [], ignoreList: [] },52 { path: 'lines/Line2.js', dependencies: [ { name: 'LineSegments2', path: 'lines/LineSegments2.js' }, { name: 'LineGeometry', path: 'lines/LineGeometry.js' }, { name: 'LineMaterial', path: 'lines/LineMaterial.js' } ], ignoreList: [] },53 { path: 'lines/LineGeometry.js', dependencies: [ { name: 'LineSegmentsGeometry', path: 'lines/LineSegmentsGeometry.js' } ], ignoreList: [] },54 { path: 'lines/LineMaterial.js', dependencies: [], ignoreList: [] },55 { path: 'lines/LineSegments2.js', dependencies: [ { name: 'LineSegmentsGeometry', path: 'lines/LineSegmentsGeometry.js' }, { name: 'LineMaterial', path: 'lines/LineMaterial.js' } ], ignoreList: [] },56 { path: 'lines/LineSegmentsGeometry.js', dependencies: [], ignoreList: [] },57 { path: 'lines/Wireframe.js', dependencies: [ { name: 'LineSegmentsGeometry', path: 'lines/LineSegmentsGeometry.js' }, { name: 'LineMaterial', path: 'lines/LineMaterial.js' } ], ignoreList: [] },58 { path: 'lines/WireframeGeometry2.js', dependencies: [ { name: 'LineSegmentsGeometry', path: 'lines/LineSegmentsGeometry.js' } ], ignoreList: [] },59 { path: 'loaders/3MFLoader.js', dependencies: [], ignoreList: [] },60 { path: 'loaders/AMFLoader.js', dependencies: [], ignoreList: [] },61 { path: 'loaders/AssimpLoader.js', dependencies: [], ignoreList: [] },62 { path: 'loaders/BasisTextureLoader.js', dependencies: [], ignoreList: [] },63 { path: 'loaders/BVHLoader.js', dependencies: [], ignoreList: [ 'Bones' ] },64 { path: 'loaders/ColladaLoader.js', dependencies: [ { name: 'TGALoader', path: 'loaders/TGALoader.js' } ], ignoreList: [] },65 { path: 'loaders/DDSLoader.js', dependencies: [], ignoreList: [] },66 { path: 'loaders/DRACOLoader.js', dependencies: [], ignoreList: [ 'LoadingManager' ] },67 { path: 'loaders/EXRLoader.js', dependencies: [ { name: 'Zlib', path: 'libs/inflate.module.min.js' } ], ignoreList: [] },68 { path: 'loaders/FBXLoader.js', dependencies: [ { name: 'Zlib', path: 'libs/inflate.module.min.js' }, { name: 'NURBSCurve', path: 'curves/NURBSCurve.js' } ], ignoreList: [] },69 { path: 'loaders/GCodeLoader.js', dependencies: [], ignoreList: [] },70 { path: 'loaders/GLTFLoader.js', dependencies: [], ignoreList: [ 'NoSide', 'Matrix2', 'Camera', 'Texture' ] },71 { path: 'loaders/HDRCubeTextureLoader.js', dependencies: [ { name: 'RGBELoader', path: 'loaders/RGBELoader.js' } ], ignoreList: [] },72 { path: 'loaders/KMZLoader.js', dependencies: [ { name: 'ColladaLoader', path: 'loaders/ColladaLoader.js' } ], ignoreList: [] },73 { path: 'loaders/LDrawLoader.js', dependencies: [], ignoreList: [ 'Cache', 'Material', 'Object3D' ] },74 { path: 'loaders/LWOLoader.js', dependencies: [], ignoreList: [] },75 { path: 'loaders/KTXLoader.js', dependencies: [], ignoreList: [] },76 { path: 'loaders/MD2Loader.js', dependencies: [], ignoreList: [] },77 { path: 'loaders/MMDLoader.js', dependencies: [ { name: 'TGALoader', path: 'loaders/TGALoader.js' }, { name: 'MMDParser', path: 'libs/mmdparser.module.js' } ], ignoreList: [ 'Camera', 'LoadingManager' ] },78 { path: 'loaders/MTLLoader.js', dependencies: [], ignoreList: [ 'BackSide', 'DoubleSide', 'ClampToEdgeWrapping', 'MirroredRepeatWrapping' ] },79 { path: 'loaders/NRRDLoader.js', dependencies: [ { name: 'Zlib', path: 'libs/gunzip.module.min.js' }, { name: 'Volume', path: 'misc/Volume.js' } ], ignoreList: [] },80 { path: 'loaders/OBJLoader.js', dependencies: [], ignoreList: [] },81 { path: 'loaders/PCDLoader.js', dependencies: [], ignoreList: [] },82 { path: 'loaders/PDBLoader.js', dependencies: [], ignoreList: [] },83 { path: 'loaders/PLYLoader.js', dependencies: [], ignoreList: [ 'Mesh' ] },84 { path: 'loaders/PRWMLoader.js', dependencies: [], ignoreList: [] },85 { path: 'loaders/PVRLoader.js', dependencies: [], ignoreList: [] },86 { path: 'loaders/RGBELoader.js', dependencies: [], ignoreList: [ 'RGBAFormat' ] },87 { path: 'loaders/STLLoader.js', dependencies: [], ignoreList: [ 'Mesh', 'MeshPhongMaterial', 'VertexColors' ] },88 { path: 'loaders/SVGLoader.js', dependencies: [], ignoreList: [] },89 { path: 'loaders/TDSLoader.js', dependencies: [], ignoreList: [] },90 { path: 'loaders/TGALoader.js', dependencies: [], ignoreList: [] },91 { path: 'loaders/TTFLoader.js', dependencies: [], ignoreList: [ 'Font' ] },92 { path: 'loaders/VRMLLoader.js', dependencies: [ { name: 'chevrotain', path: 'libs/chevrotain.module.min.js' } ], ignoreList: [] },93 { path: 'loaders/VRMLoader.js', dependencies: [ { name: 'GLTFLoader', path: 'loaders/GLTFLoader.js' } ], ignoreList: [] },94 { path: 'loaders/VTKLoader.js', dependencies: [ { name: 'Zlib', path: 'libs/inflate.module.min.js' } ], ignoreList: [] },95 { path: 'loaders/XLoader.js', dependencies: [], ignoreList: [] },96 { path: 'math/ColorConverter.js', dependencies: [], ignoreList: [] },97 { path: 'math/ConvexHull.js', dependencies: [], ignoreList: [] },98 { path: 'math/ImprovedNoise.js', dependencies: [], ignoreList: [] },99 { path: 'math/Lut.js', dependencies: [], ignoreList: [] },100 { path: 'math/SimplexNoise.js', dependencies: [], ignoreList: [] },101 { path: 'misc/CarControls.js', dependencies: [], ignoreList: [] },102 { path: 'misc/ConvexObjectBreaker.js', dependencies: [ { name: 'ConvexBufferGeometry', path: 'geometries/ConvexGeometry.js' } ], ignoreList: [ 'Matrix4' ] },103 { path: 'misc/Gyroscope.js', dependencies: [], ignoreList: [] },104 { path: 'misc/MD2Character.js', dependencies: [ { name: 'MD2Loader', path: 'loaders/MD2Loader.js' } ], ignoreList: [] },105 { path: 'misc/MD2CharacterComplex.js', dependencies: [ { name: 'MD2Loader', path: 'loaders/MD2Loader.js' }, { name: 'MorphBlendMesh', path: 'misc/MorphBlendMesh.js' } ], ignoreList: [] },106 { path: 'misc/MorphAnimMesh.js', dependencies: [], ignoreList: [] },107 { path: 'misc/MorphBlendMesh.js', dependencies: [], ignoreList: [] },108 { path: 'misc/Ocean.js', dependencies: [ { name: 'OceanShaders', path: 'shaders/OceanShaders.js' } ], ignoreList: [] },109 { path: 'misc/RollerCoaster.js', dependencies: [], ignoreList: [] },110 { path: 'misc/Volume.js', dependencies: [ { name: 'VolumeSlice', path: 'misc/VolumeSlice.js' } ], ignoreList: [] },111 { path: 'misc/VolumeSlice.js', dependencies: [], ignoreList: [] },112 { path: 'modifiers/ExplodeModifier.js', dependencies: [], ignoreList: [] },113 { path: 'modifiers/SimplifyModifier.js', dependencies: [], ignoreList: [] },114 { path: 'modifiers/SubdivisionModifier.js', dependencies: [], ignoreList: [] },115 { path: 'modifiers/TessellateModifier.js', dependencies: [], ignoreList: [] },116 { path: 'objects/Fire.js', dependencies: [], ignoreList: [] },117 { path: 'objects/Lensflare.js', dependencies: [], ignoreList: [] },118 { path: 'objects/LightningStorm.js', dependencies: [ { name: 'LightningStrike', path: 'geometries/LightningStrike.js' } ], ignoreList: [ 'Material' ] },119 { path: 'objects/MarchingCubes.js', dependencies: [], ignoreList: [] },120 { path: 'objects/Reflector.js', dependencies: [], ignoreList: [] },121 { path: 'objects/Refractor.js', dependencies: [], ignoreList: [] },122 { path: 'objects/ReflectorRTT.js', dependencies: [ { name: 'Reflector', path: 'objects/Reflector.js' } ], ignoreList: [] },123 { path: 'objects/ShadowMesh.js', dependencies: [], ignoreList: [] },124 { path: 'objects/Sky.js', dependencies: [], ignoreList: [] },125 { path: 'objects/Water.js', dependencies: [], ignoreList: [] },126 { path: 'objects/Water2.js', dependencies: [ { name: 'Reflector', path: 'objects/Reflector.js' }, { name: 'Refractor', path: 'objects/Refractor.js' } ], ignoreList: [] },127 { path: 'pmrem/PMREMCubeUVPacker.js', dependencies: [], ignoreList: [] },128 { path: 'pmrem/PMREMGenerator.js', dependencies: [], ignoreList: [] },129 { path: 'postprocessing/AdaptiveToneMappingPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' }, { name: 'LuminosityShader', path: 'shaders/LuminosityShader.js' }, { name: 'ToneMapShader', path: 'shaders/ToneMapShader.js' } ], ignoreList: [] },130 { path: 'postprocessing/AfterimagePass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'AfterimageShader', path: 'shaders/AfterimageShader.js' } ], ignoreList: [] },131 { path: 'postprocessing/BloomPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' }, { name: 'ConvolutionShader', path: 'shaders/ConvolutionShader.js' } ], ignoreList: [] },132 { path: 'postprocessing/BokehPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'BokehShader', path: 'shaders/BokehShader.js' } ], ignoreList: [] },133 { path: 'postprocessing/ClearPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' } ], ignoreList: [] },134 { path: 'postprocessing/CubeTexturePass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' } ], ignoreList: [] },135 { path: 'postprocessing/DotScreenPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'DotScreenShader', path: 'shaders/DotScreenShader.js' } ], ignoreList: [] },136 { path: 'postprocessing/EffectComposer.js', dependencies: [ { name: 'CopyShader', path: 'shaders/CopyShader.js' }, { name: 'ShaderPass', path: 'postprocessing/ShaderPass.js' }, { name: 'MaskPass', path: 'postprocessing/MaskPass.js' }, { name: 'ClearMaskPass', path: 'postprocessing/MaskPass.js' } ], ignoreList: [] },137 { path: 'postprocessing/FilmPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'FilmShader', path: 'shaders/FilmShader.js' } ], ignoreList: [] },138 { path: 'postprocessing/GlitchPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'DigitalGlitch', path: 'shaders/DigitalGlitch.js' } ], ignoreList: [] },139 { path: 'postprocessing/HalftonePass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'HalftoneShader', path: 'shaders/HalftoneShader.js' } ], ignoreList: [] },140 { path: 'postprocessing/MaskPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' } ], ignoreList: [] },141 { path: 'postprocessing/OutlinePass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' } ], ignoreList: [] },142 { path: 'postprocessing/RenderPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' } ], ignoreList: [] },143 { path: 'postprocessing/SAOPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'SAOShader', path: 'shaders/SAOShader.js' }, { name: 'DepthLimitedBlurShader', path: 'shaders/DepthLimitedBlurShader.js' }, { name: 'BlurShaderUtils', path: 'shaders/DepthLimitedBlurShader.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' }, { name: 'UnpackDepthRGBAShader', path: 'shaders/UnpackDepthRGBAShader.js' } ], ignoreList: [] },144 { path: 'postprocessing/SavePass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' } ], ignoreList: [] },145 { path: 'postprocessing/ShaderPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' } ], ignoreList: [] },146 { path: 'postprocessing/SMAAPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'SMAAEdgesShader', path: 'shaders/SMAAShader.js' }, { name: 'SMAAWeightsShader', path: 'shaders/SMAAShader.js' }, { name: 'SMAABlendShader', path: 'shaders/SMAAShader.js' } ], ignoreList: [] },147 { path: 'postprocessing/SSAARenderPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' } ], ignoreList: [] },148 { path: 'postprocessing/SSAOPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'SimplexNoise', path: 'math/SimplexNoise.js' }, { name: 'SSAOShader', path: 'shaders/SSAOShader.js' }, { name: 'SSAOBlurShader', path: 'shaders/SSAOShader.js' }, { name: 'SSAODepthShader', path: 'shaders/SSAOShader.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' } ], ignoreList: [] },149 { path: 'postprocessing/TAARenderPass.js', dependencies: [ { name: 'SSAARenderPass', path: 'postprocessing/SSAARenderPass.js' } ], ignoreList: [] },150 { path: 'postprocessing/TexturePass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' } ], ignoreList: [] },151 { path: 'postprocessing/UnrealBloomPass.js', dependencies: [ { name: 'Pass', path: 'postprocessing/Pass.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' }, { name: 'LuminosityHighPassShader', path: 'shaders/LuminosityHighPassShader.js' } ], ignoreList: [] },152 { path: 'renderers/CSS2DRenderer.js', dependencies: [], ignoreList: [] },153 { path: 'renderers/CSS3DRenderer.js', dependencies: [], ignoreList: [] },154 { path: 'renderers/Projector.js', dependencies: [], ignoreList: [] },155 { path: 'renderers/RaytracingRenderer.js', dependencies: [], ignoreList: [] },156 { path: 'renderers/SVGRenderer.js', dependencies: [ { name: 'Projector', path: 'renderers/Projector.js' }, { name: 'RenderableFace', path: 'renderers/Projector.js' }, { name: 'RenderableLine', path: 'renderers/Projector.js' }, { name: 'RenderableSprite', path: 'renderers/Projector.js' } ], ignoreList: [] },157 { path: 'renderers/WebGLDeferredRenderer.js', dependencies: [ { name: 'EffectComposer', path: 'postprocessing/EffectComposer.js' }, { name: 'ShaderPass', path: 'postprocessing/ShaderPass.js' }, { name: 'RenderPass', path: 'postprocessing/RenderPass.js' }, { name: 'FXAAShader', path: 'shaders/FXAAShader.js' }, { name: 'CopyShader', path: 'shaders/CopyShader.js' } ], ignoreList: [] },158 { path: 'shaders/AfterimageShader.js', dependencies: [], ignoreList: [] },159 { path: 'shaders/BasicShader.js', dependencies: [], ignoreList: [] },160 { path: 'shaders/BleachBypassShader.js', dependencies: [], ignoreList: [] },161 { path: 'shaders/BlendShader.js', dependencies: [], ignoreList: [] },162 { path: 'shaders/BokehShader.js', dependencies: [], ignoreList: [] },163 { path: 'shaders/BokehShader2.js', dependencies: [], ignoreList: [] },164 { path: 'shaders/BrightnessContrastShader.js', dependencies: [], ignoreList: [] },165 { path: 'shaders/ColorCorrectionShader.js', dependencies: [], ignoreList: [] },166 { path: 'shaders/ColorifyShader.js', dependencies: [], ignoreList: [] },167 { path: 'shaders/ConvolutionShader.js', dependencies: [], ignoreList: [] },168 { path: 'shaders/CopyShader.js', dependencies: [], ignoreList: [] },169 { path: 'shaders/DepthLimitedBlurShader.js', dependencies: [], ignoreList: [] },170 { path: 'shaders/DigitalGlitch.js', dependencies: [], ignoreList: [] },171 { path: 'shaders/DOFMipMapShader.js', dependencies: [], ignoreList: [] },172 { path: 'shaders/DotScreenShader.js', dependencies: [], ignoreList: [] },173 { path: 'shaders/FilmShader.js', dependencies: [], ignoreList: [] },174 { path: 'shaders/FocusShader.js', dependencies: [], ignoreList: [] },175 { path: 'shaders/FreiChenShader.js', dependencies: [], ignoreList: [] },176 { path: 'shaders/FresnelShader.js', dependencies: [], ignoreList: [] },177 { path: 'shaders/FXAAShader.js', dependencies: [], ignoreList: [] },178 { path: 'shaders/GammaCorrectionShader.js', dependencies: [], ignoreList: [] },179 { path: 'shaders/GodRaysShader.js', dependencies: [], ignoreList: [ 'MeshDepthMaterial' ] },180 { path: 'shaders/HalftoneShader.js', dependencies: [], ignoreList: [] },181 { path: 'shaders/HorizontalBlurShader.js', dependencies: [], ignoreList: [] },182 { path: 'shaders/HorizontalTiltShiftShader.js', dependencies: [], ignoreList: [] },183 { path: 'shaders/HueSaturationShader.js', dependencies: [], ignoreList: [] },184 { path: 'shaders/KaleidoShader.js', dependencies: [], ignoreList: [] },185 { path: 'shaders/LuminosityHighPassShader.js', dependencies: [], ignoreList: [] },186 { path: 'shaders/LuminosityShader.js', dependencies: [], ignoreList: [] },187 { path: 'shaders/MirrorShader.js', dependencies: [], ignoreList: [] },188 { path: 'shaders/NormalMapShader.js', dependencies: [], ignoreList: [] },189 { path: 'shaders/OceanShaders.js', dependencies: [], ignoreList: [] },190 { path: 'shaders/ParallaxShader.js', dependencies: [], ignoreList: [] },191 { path: 'shaders/PixelShader.js', dependencies: [], ignoreList: [] },192 { path: 'shaders/RGBShiftShader.js', dependencies: [], ignoreList: [] },193 { path: 'shaders/SAOShader.js', dependencies: [], ignoreList: [] },194 { path: 'shaders/SepiaShader.js', dependencies: [], ignoreList: [] },195 { path: 'shaders/SkinShader.js', dependencies: [], ignoreList: [] },196 { path: 'shaders/SMAAShader.js', dependencies: [], ignoreList: [] },197 { path: 'shaders/SobelOperatorShader.js', dependencies: [], ignoreList: [] },198 { path: 'shaders/SSAOShader.js', dependencies: [], ignoreList: [] },199 { path: 'shaders/TechnicolorShader.js', dependencies: [], ignoreList: [] },200 { path: 'shaders/TerrainShader.js', dependencies: [], ignoreList: [] },201 { path: 'shaders/ToneMapShader.js', dependencies: [], ignoreList: [] },202 { path: 'shaders/ToonShader.js', dependencies: [], ignoreList: [] },203 { path: 'shaders/TranslucentShader.js', dependencies: [], ignoreList: [] },204 { path: 'shaders/TriangleBlurShader.js', dependencies: [], ignoreList: [] },205 { path: 'shaders/UnpackDepthRGBAShader.js', dependencies: [], ignoreList: [] },206 { path: 'shaders/VerticalBlurShader.js', dependencies: [], ignoreList: [] },207 { path: 'shaders/VerticalTiltShiftShader.js', dependencies: [], ignoreList: [] },208 { path: 'shaders/VignetteShader.js', dependencies: [], ignoreList: [] },209 { path: 'shaders/VolumeShader.js', dependencies: [], ignoreList: [] },210 { path: 'shaders/WaterRefractionShader.js', dependencies: [], ignoreList: [] },211 { path: 'utils/BufferGeometryUtils.js', dependencies: [], ignoreList: [] },212 { path: 'utils/GeometryUtils.js', dependencies: [], ignoreList: [] },213 { path: 'utils/MathUtils.js', dependencies: [], ignoreList: [] },214 { path: 'utils/SceneUtils.js', dependencies: [], ignoreList: [] },215 { path: 'utils/ShadowMapViewer.js', dependencies: [ { name: 'UnpackDepthRGBAShader', path: 'shaders/UnpackDepthRGBAShader.js' } ], ignoreList: [ 'DirectionalLight', 'SpotLight' ] },216 { path: 'utils/SkeletonUtils.js', dependencies: [], ignoreList: [] },217 { path: 'utils/TypedArrayUtils.js', dependencies: [], ignoreList: [] },218 { path: 'utils/UVsDebug.js', dependencies: [], ignoreList: [ 'SphereBufferGeometry' ] },219 { path: 'vr/WebVR.js', dependencies: [], ignoreList: [] },220 { path: 'WebGL.js', dependencies: [], ignoreList: [] },221];222for ( var i = 0; i < files.length; i ++ ) {223 var file = files[ i ];224 convert( file.path, file.dependencies, file.ignoreList );225}226//227function convert( path, exampleDependencies, ignoreList ) {228 var contents = fs.readFileSync( srcFolder + path, 'utf8' );229 var classNames = [];230 var coreDependencies = {};231 // imports232 contents = contents.replace( /^\/\*+[^*]*\*+(?:[^/*][^*]*\*+)*\//, function ( match ) {233 return `${match}\n\n_IMPORTS_`;234 } );235 // class name236 contents = contents.replace( /THREE\.([a-zA-Z0-9]+) = /g, function ( match, p1 ) {237 classNames.push( p1 );238 console.log( p1 );239 return `var ${p1} = `;240 } );241 contents = contents.replace( /(\'?)THREE\.([a-zA-Z0-9]+)(\.{0,1})/g, function ( match, p1, p2, p3 ) {242 if ( p1 === '\'' ) return match; // Inside a string243 if ( classNames.includes( p2 ) ) return `${p2}${p3}`;244 if ( p1 === 'Math' ) {245 coreDependencies[ '_Math' ] = true;246 return '_Math.';247 }248 return match;249 } );250 // methods251 contents = contents.replace( /new THREE\.([a-zA-Z0-9]+)\(/g, function ( match, p1 ) {252 if ( ignoreList.includes( p1 ) ) return match;253 if ( p1 in THREE ) coreDependencies[ p1 ] = true;254 return `new ${p1}(`;255 } );256 // constants257 contents = contents.replace( /(\'?)THREE\.([a-zA-Z0-9_]+)/g, function ( match, p1, p2 ) {258 if ( ignoreList.includes( p2 ) ) return match;259 if ( p1 === '\'' ) return match; // Inside a string260 if ( classNames.includes( p2 ) ) return p2;261 if ( p2 === 'Math' || p2 === '_Math' ) {262 coreDependencies[ '_Math' ] = true;263 return '_Math';264 }265 if ( p2 in THREE ) coreDependencies[ p2 ] = true;266 // console.log( match, p2 );267 return `${p2}`;268 } );269 //270 var keys = Object.keys( coreDependencies )271 .filter( value => ! classNames.includes( value ) )272 .map( value => value === '_Math' ? 'Math as _Math' : value )273 .map( value => '\n\t' + value )274 .sort()275 .toString();276 var imports = '';277 // compute path prefix for imports/exports278 var level = path.split( '/' ).length - 1;279 var pathPrefix = '../'.repeat( level );280 // core imports281 if ( keys ) imports += `import {${keys}\n} from "${pathPrefix}../../build/three.module.js";`;282 // example imports283 for ( var dependency of exampleDependencies ) {284 imports += `\nimport { ${dependency.name} } from "${pathPrefix}${dependency.path}";`;285 }286 // exports287 var exports = `export { ${classNames.join( ", " )} };\n`;288 var output = contents.replace( '_IMPORTS_', imports ) + '\n' + exports;289 // console.log( output );290 fs.writeFileSync( dstFolder + path, output, 'utf-8' );...

Full Screen

Full Screen

diff.min.js

Source:diff.min.js Github

copy

Full Screen

1/*!2 diff v3.2.03Software License Agreement (BSD License)4Copyright (c) 2009-2015, Kevin Decker <kpdecker@gmail.com>5All rights reserved.6Redistribution and use of this software in source and binary forms, with or without modification,7are permitted provided that the following conditions are met:8* Redistributions of source code must retain the above9 copyright notice, this list of conditions and the10 following disclaimer.11* Redistributions in binary form must reproduce the above12 copyright notice, this list of conditions and the13 following disclaimer in the documentation and/or other14 materials provided with the distribution.15* Neither the name of Kevin Decker nor the names of its16 contributors may be used to endorse or promote products17 derived from this software without specific prior18 written permission.19THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR20IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND21FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR22CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL23DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,24DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER25IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT26OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.27@license28*/29!function(a,b){"object"==typeof exports&&"object"==typeof module?module.exports=b():"function"==typeof define&&define.amd?define([],b):"object"==typeof exports?exports.JsDiff=b():a.JsDiff=b()}(this,function(){/******/30return function(a){/******/31// The require function32/******/33function b(d){/******/34// Check if module is in cache35/******/36if(c[d])/******/37return c[d].exports;/******/38// Create a new module (and put it into the cache)39/******/40var e=c[d]={/******/41exports:{},/******/42id:d,/******/43loaded:!1};/******/44// Return the exports of the module45/******/46/******/47// Execute the module function48/******/49/******/50// Flag the module as loaded51/******/52return a[d].call(e.exports,e,e.exports,b),e.loaded=!0,e.exports}// webpackBootstrap53/******/54// The module cache55/******/56var c={};/******/57// Load entry module and return exports58/******/59/******/60// expose the modules object (__webpack_modules__)61/******/62/******/63// expose the module cache64/******/65/******/66// __webpack_public_path__67/******/68return b.m=a,b.c=c,b.p="",b(0)}([/* 0 */69/***/70function(a,b,c){/*istanbul ignore start*/71"use strict";/*istanbul ignore start*/72function d(a){return a&&a.__esModule?a:{"default":a}}b.__esModule=!0,b.canonicalize=b.convertChangesToXML=b.convertChangesToDMP=b.parsePatch=b.applyPatches=b.applyPatch=b.createPatch=b.createTwoFilesPatch=b.structuredPatch=b.diffArrays=b.diffJson=b.diffCss=b.diffSentences=b.diffTrimmedLines=b.diffLines=b.diffWordsWithSpace=b.diffWords=b.diffChars=b.Diff=void 0;/*istanbul ignore end*/73var/*istanbul ignore start*/e=c(1),f=d(e),/*istanbul ignore start*/g=c(2),/*istanbul ignore start*/h=c(3),/*istanbul ignore start*/i=c(5),/*istanbul ignore start*/j=c(6),/*istanbul ignore start*/k=c(7),/*istanbul ignore start*/l=c(8),/*istanbul ignore start*/m=c(9),/*istanbul ignore start*/n=c(10),/*istanbul ignore start*/o=c(11),/*istanbul ignore start*/p=c(13),/*istanbul ignore start*/q=c(14),/*istanbul ignore start*/r=c(15);b.Diff=f["default"],/*istanbul ignore start*/74b.diffChars=g.diffChars,/*istanbul ignore start*/75b.diffWords=h.diffWords,/*istanbul ignore start*/76b.diffWordsWithSpace=h.diffWordsWithSpace,/*istanbul ignore start*/77b.diffLines=i.diffLines,/*istanbul ignore start*/78b.diffTrimmedLines=i.diffTrimmedLines,/*istanbul ignore start*/79b.diffSentences=j.diffSentences,/*istanbul ignore start*/80b.diffCss=k.diffCss,/*istanbul ignore start*/81b.diffJson=l.diffJson,/*istanbul ignore start*/82b.diffArrays=m.diffArrays,/*istanbul ignore start*/83b.structuredPatch=p.structuredPatch,/*istanbul ignore start*/84b.createTwoFilesPatch=p.createTwoFilesPatch,/*istanbul ignore start*/85b.createPatch=p.createPatch,/*istanbul ignore start*/86b.applyPatch=n.applyPatch,/*istanbul ignore start*/87b.applyPatches=n.applyPatches,/*istanbul ignore start*/88b.parsePatch=o.parsePatch,/*istanbul ignore start*/89b.convertChangesToDMP=q.convertChangesToDMP,/*istanbul ignore start*/90b.convertChangesToXML=r.convertChangesToXML,/*istanbul ignore start*/91b.canonicalize=l.canonicalize},/* 1 */92/***/93function(a,b){/*istanbul ignore start*/94"use strict";function c(){}function d(a,b,c,d,e){for(var f=0,g=b.length,h=0,i=0;f<g;f++){var j=b[f];if(j.removed){95// Reverse add and remove so removes are output first to match common convention96// The diffing algorithm is tied to add then remove output and this is the simplest97// route to get the desired output with minimal overhead.98if(j.value=a.join(d.slice(i,i+j.count)),i+=j.count,f&&b[f-1].added){var k=b[f-1];b[f-1]=b[f],b[f]=k}}else{if(!j.added&&e){var l=c.slice(h,h+j.count);l=l.map(function(a,b){var c=d[i+b];return c.length>a.length?c:a}),j.value=a.join(l)}else j.value=a.join(c.slice(h,h+j.count));h+=j.count,99// Common case100j.added||(i+=j.count)}}101// Special case handle for when one terminal is ignored. For this case we merge the102// terminal into the prior string and drop the change.103var m=b[g-1];return g>1&&(m.added||m.removed)&&a.equals("",m.value)&&(b[g-2].value+=m.value,b.pop()),b}function e(a){return{newPos:a.newPos,components:a.components.slice(0)}}b.__esModule=!0,b["default"]=/*istanbul ignore end*/c,c.prototype={/*istanbul ignore start*/104/*istanbul ignore end*/105diff:function(a,b){function c(a){return h?(setTimeout(function(){h(void 0,a)},0),!0):a}106// Main worker method. checks all permutations of a given edit length for acceptance.107function f(){for(var f=-1*l;f<=l;f+=2){var g=/*istanbul ignore start*/void 0,h=n[f-1],m=n[f+1],o=(m?m.newPos:0)-f;h&&(108// No one else is going to attempt to use this value, clear it109n[f-1]=void 0);var p=h&&h.newPos+1<j,q=m&&0<=o&&o<k;if(p||q){110// If we have hit the end of both strings, then we are done111if(112// Select the diagonal that we want to branch from. We select the prior113// path whose position in the new string is the farthest from the origin114// and does not pass the bounds of the diff graph115!p||q&&h.newPos<m.newPos?(g=e(m),i.pushComponent(g.components,void 0,!0)):(g=h,// No need to clone, we've pulled it from the list116g.newPos++,i.pushComponent(g.components,!0,void 0)),o=i.extractCommon(g,b,a,f),g.newPos+1>=j&&o+1>=k)return c(d(i,g.components,b,a,i.useLongestToken));117// Otherwise track this path as a potential candidate and continue.118n[f]=g}else119// If this path is a terminal then prune120n[f]=void 0}l++}/*istanbul ignore start*/121var/*istanbul ignore end*/g=arguments.length<=2||void 0===arguments[2]?{}:arguments[2],h=g.callback;"function"==typeof g&&(h=g,g={}),this.options=g;var i=this;122// Allow subclasses to massage the input prior to running123a=this.castInput(a),b=this.castInput(b),a=this.removeEmpty(this.tokenize(a)),b=this.removeEmpty(this.tokenize(b));var j=b.length,k=a.length,l=1,m=j+k,n=[{newPos:-1,components:[]}],o=this.extractCommon(n[0],b,a,0);if(n[0].newPos+1>=j&&o+1>=k)124// Identity per the equality and tokenizer125return c([{value:this.join(b),count:b.length}]);126// Performs the length of edit iteration. Is a bit fugly as this has to support the127// sync and async mode which is never fun. Loops over execEditLength until a value128// is produced.129if(h)!function q(){setTimeout(function(){130// This should not happen, but we want to be safe.131/* istanbul ignore next */132// This should not happen, but we want to be safe.133/* istanbul ignore next */134return l>m?h():void(f()||q())},0)}();else for(;l<=m;){var p=f();if(p)return p}},/*istanbul ignore start*/135/*istanbul ignore end*/136pushComponent:function(a,b,c){var d=a[a.length-1];d&&d.added===b&&d.removed===c?137// We need to clone here as the component clone operation is just138// as shallow array clone139a[a.length-1]={count:d.count+1,added:b,removed:c}:a.push({count:1,added:b,removed:c})},/*istanbul ignore start*/140/*istanbul ignore end*/141extractCommon:function(a,b,c,d){for(var e=b.length,f=c.length,g=a.newPos,h=g-d,i=0;g+1<e&&h+1<f&&this.equals(b[g+1],c[h+1]);)g++,h++,i++;return i&&a.components.push({count:i}),a.newPos=g,h},/*istanbul ignore start*/142/*istanbul ignore end*/143equals:function(a,b){return a===b},/*istanbul ignore start*/144/*istanbul ignore end*/145removeEmpty:function(a){for(var b=[],c=0;c<a.length;c++)a[c]&&b.push(a[c]);return b},/*istanbul ignore start*/146/*istanbul ignore end*/147castInput:function(a){return a},/*istanbul ignore start*/148/*istanbul ignore end*/149tokenize:function(a){return a.split("")},/*istanbul ignore start*/150/*istanbul ignore end*/151join:function(a){return a.join("")}}},/* 2 */152/***/153function(a,b,c){/*istanbul ignore start*/154"use strict";function d(a){return a&&a.__esModule?a:{"default":a}}function e(a,b,c){return h.diff(a,b,c)}b.__esModule=!0,b.characterDiff=void 0,b.diffChars=e;var/*istanbul ignore start*/f=c(1),g=d(f),h=/*istanbul ignore start*/b.characterDiff=new/*istanbul ignore start*/g["default"]},/* 3 */155/***/156function(a,b,c){/*istanbul ignore start*/157"use strict";/*istanbul ignore start*/158function d(a){return a&&a.__esModule?a:{"default":a}}function e(a,b,c){var d=/*istanbul ignore start*/(0,i.generateOptions)(c,{ignoreWhitespace:!0});return l.diff(a,b,d)}function f(a,b,c){return l.diff(a,b,c)}b.__esModule=!0,b.wordDiff=void 0,b.diffWords=e,/*istanbul ignore start*/159b.diffWordsWithSpace=f;var/*istanbul ignore start*/g=c(1),h=d(g),/*istanbul ignore start*/i=c(4),j=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,k=/\S/,l=/*istanbul ignore start*/b.wordDiff=new/*istanbul ignore start*/h["default"];l.equals=function(a,b){return a===b||this.options.ignoreWhitespace&&!k.test(a)&&!k.test(b)},l.tokenize=function(a){160// Join the boundary splits that we do not consider to be boundaries. This is primarily the extended Latin character set.161for(var b=a.split(/(\s+|\b)/),c=0;c<b.length-1;c++)162// If we have an empty string in the next field and we have only word chars before and after, merge163!b[c+1]&&b[c+2]&&j.test(b[c])&&j.test(b[c+2])&&(b[c]+=b[c+2],b.splice(c+1,2),c--);return b}},/* 4 */164/***/165function(a,b){/*istanbul ignore start*/166"use strict";function c(a,b){if("function"==typeof a)b.callback=a;else if(a)for(var c in a)/* istanbul ignore else */167a.hasOwnProperty(c)&&(b[c]=a[c]);return b}b.__esModule=!0,b.generateOptions=c},/* 5 */168/***/169function(a,b,c){/*istanbul ignore start*/170"use strict";/*istanbul ignore start*/171function d(a){return a&&a.__esModule?a:{"default":a}}function e(a,b,c){return j.diff(a,b,c)}function f(a,b,c){var d=/*istanbul ignore start*/(0,i.generateOptions)(c,{ignoreWhitespace:!0});return j.diff(a,b,d)}b.__esModule=!0,b.lineDiff=void 0,b.diffLines=e,/*istanbul ignore start*/172b.diffTrimmedLines=f;var/*istanbul ignore start*/g=c(1),h=d(g),/*istanbul ignore start*/i=c(4),j=/*istanbul ignore start*/b.lineDiff=new/*istanbul ignore start*/h["default"];j.tokenize=function(a){var b=[],c=a.split(/(\n|\r\n)/);173// Ignore the final empty token that occurs if the string ends with a new line174c[c.length-1]||c.pop();175// Merge the content and line separators into single tokens176for(var d=0;d<c.length;d++){var e=c[d];d%2&&!this.options.newlineIsToken?b[b.length-1]+=e:(this.options.ignoreWhitespace&&(e=e.trim()),b.push(e))}return b}},/* 6 */177/***/178function(a,b,c){/*istanbul ignore start*/179"use strict";function d(a){return a&&a.__esModule?a:{"default":a}}function e(a,b,c){return h.diff(a,b,c)}b.__esModule=!0,b.sentenceDiff=void 0,b.diffSentences=e;var/*istanbul ignore start*/f=c(1),g=d(f),h=/*istanbul ignore start*/b.sentenceDiff=new/*istanbul ignore start*/g["default"];h.tokenize=function(a){return a.split(/(\S.+?[.!?])(?=\s+|$)/)}},/* 7 */180/***/181function(a,b,c){/*istanbul ignore start*/182"use strict";function d(a){return a&&a.__esModule?a:{"default":a}}function e(a,b,c){return h.diff(a,b,c)}b.__esModule=!0,b.cssDiff=void 0,b.diffCss=e;var/*istanbul ignore start*/f=c(1),g=d(f),h=/*istanbul ignore start*/b.cssDiff=new/*istanbul ignore start*/g["default"];h.tokenize=function(a){return a.split(/([{}:;,]|\s+)/)}},/* 8 */183/***/184function(a,b,c){/*istanbul ignore start*/185"use strict";/*istanbul ignore start*/186function d(a){return a&&a.__esModule?a:{"default":a}}function e(a,b,c){return l.diff(a,b,c)}187// This function handles the presence of circular references by bailing out when encountering an188// object that is already on the "stack" of items being processed.189function f(a,b,c){b=b||[],c=c||[];var d=/*istanbul ignore start*/void 0;for(d=0;d<b.length;d+=1)if(b[d]===a)return c[d];var e=/*istanbul ignore start*/void 0;if("[object Array]"===k.call(a)){for(b.push(a),e=new Array(a.length),c.push(e),d=0;d<a.length;d+=1)e[d]=f(a[d],b,c);return b.pop(),c.pop(),e}if(a&&a.toJSON&&(a=a.toJSON()),/*istanbul ignore start*/"object"===("undefined"==typeof/*istanbul ignore end*/a?"undefined":g(a))&&null!==a){b.push(a),e={},c.push(e);var h=[],i=/*istanbul ignore start*/void 0;for(i in a)/* istanbul ignore else */190a.hasOwnProperty(i)&&h.push(i);for(h.sort(),d=0;d<h.length;d+=1)i=h[d],e[i]=f(a[i],b,c);b.pop(),c.pop()}else e=a;return e}b.__esModule=!0,b.jsonDiff=void 0;var g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol?"symbol":typeof a};b.diffJson=e,/*istanbul ignore start*/191b.canonicalize=f;var/*istanbul ignore start*/h=c(1),i=d(h),/*istanbul ignore start*/j=c(5),k=Object.prototype.toString,l=/*istanbul ignore start*/b.jsonDiff=new/*istanbul ignore start*/i["default"];192// Discriminate between two lines of pretty-printed, serialized JSON where one of them has a193// dangling comma and the other doesn't. Turns out including the dangling comma yields the nicest output:194l.useLongestToken=!0,l.tokenize=/*istanbul ignore start*/j.lineDiff.tokenize,l.castInput=function(a){/*istanbul ignore start*/195var/*istanbul ignore end*/b=this.options.undefinedReplacement;return"string"==typeof a?a:JSON.stringify(f(a),function(a,c){return"undefined"==typeof c?b:c}," ")},l.equals=function(a,b){/*istanbul ignore start*/196return i["default"].prototype.equals(a.replace(/,([\r\n])/g,"$1"),b.replace(/,([\r\n])/g,"$1"))}},/* 9 */197/***/198function(a,b,c){/*istanbul ignore start*/199"use strict";function d(a){return a&&a.__esModule?a:{"default":a}}function e(a,b,c){return h.diff(a,b,c)}b.__esModule=!0,b.arrayDiff=void 0,b.diffArrays=e;var/*istanbul ignore start*/f=c(1),g=d(f),h=/*istanbul ignore start*/b.arrayDiff=new/*istanbul ignore start*/g["default"];h.tokenize=h.join=function(a){return a.slice()}},/* 10 */200/***/201function(a,b,c){/*istanbul ignore start*/202"use strict";function d(a){return a&&a.__esModule?a:{"default":a}}/*istanbul ignore end*/203function e(a,b){/**204 * Checks if the hunk exactly fits on the provided location205 */206function c(a,b){for(var c=0;c<a.lines.length;c++){var d=a.lines[c],f=d[0],g=d.substr(1);if(" "===f||"-"===f){207// Context sanity check208if(!j(b+1,e[b],f,g)&&(k++,k>l))return!1;b++}}return!0}/*istanbul ignore start*/209var/*istanbul ignore end*/d=arguments.length<=2||void 0===arguments[2]?{}:arguments[2];if("string"==typeof b&&(b=/*istanbul ignore start*/(0,g.parsePatch)(b)),Array.isArray(b)){if(b.length>1)throw new Error("applyPatch only works with a single input.");b=b[0]}210// Search best fit offsets for each hunk based on the previous ones211for(var e=a.split(/\r\n|[\n\v\f\r\x85]/),f=a.match(/\r\n|[\n\v\f\r\x85]/g)||[],h=b.hunks,j=d.compareLine||function(a,b,c,d){/*istanbul ignore end*/212return b===d},k=0,l=d.fuzzFactor||0,m=0,n=0,o=/*istanbul ignore start*/void 0,p=/*istanbul ignore start*/void 0,q=0;q<h.length;q++){for(var r=h[q],s=e.length-r.oldLines,t=0,u=n+r.oldStart-1,v=/*istanbul ignore start*/(0,i["default"])(u,m,s);void 0!==t;t=v())if(c(r,u+t)){r.offset=n+=t;break}if(void 0===t)return!1;213// Set lower text limit to end of the current hunk, so next ones don't try214// to fit over already patched text215m=r.offset+r.oldStart+r.oldLines}216// Apply patch hunks217for(var w=0;w<h.length;w++){var x=h[w],y=x.offset+x.newStart-1;0==x.newLines&&y++;for(var z=0;z<x.lines.length;z++){var A=x.lines[z],B=A[0],C=A.substr(1),D=x.linedelimiters[z];if(" "===B)y++;else if("-"===B)e.splice(y,1),f.splice(y,1);else if("+"===B)e.splice(y,0,C),f.splice(y,0,D),y++;else if("\\"===B){var E=x.lines[z-1]?x.lines[z-1][0]:null;"+"===E?o=!0:"-"===E&&(p=!0)}}}218// Handle EOFNL insertion/removal219if(o)for(;!e[e.length-1];)e.pop(),f.pop();else p&&(e.push(""),f.push("\n"));for(var F=0;F<e.length-1;F++)e[F]=e[F]+f[F];return e.join("")}220// Wrapper that supports multiple file patches via callbacks.221function f(a,b){function c(){var f=a[d++];return f?void b.loadFile(f,function(a,d){if(a)return b.complete(a);var g=e(d,f,b);b.patched(f,g,function(a){return a?b.complete(a):void c()})}):b.complete()}"string"==typeof a&&(a=/*istanbul ignore start*/(0,g.parsePatch)(a));var d=0;c()}b.__esModule=!0,b.applyPatch=e,/*istanbul ignore start*/222b.applyPatches=f;var/*istanbul ignore start*/g=c(11),/*istanbul ignore start*/h=c(12),i=d(h)},/* 11 */223/***/224function(a,b){/*istanbul ignore start*/225"use strict";function c(a){function b(){var a={};226// Parse diff metadata227for(h.push(a);i<f.length;){var b=f[i];228// File header found, end parsing diff metadata229if(/^(\-\-\-|\+\+\+|@@)\s/.test(b))break;230// Diff index231var g=/^(?:Index:|diff(?: -r \w+)+)\s+(.+?)\s*$/.exec(b);g&&(a.index=g[1]),i++}for(232// Parse file headers if they are defined. Unified diff requires them, but233// there's no technical issues to have an isolated hunk without file header234c(a),c(a),235// Parse hunks236a.hunks=[];i<f.length;){var j=f[i];if(/^(Index:|diff|\-\-\-|\+\+\+)\s/.test(j))break;if(/^@@/.test(j))a.hunks.push(d());else{if(j&&e.strict)237// Ignore unexpected content unless in strict mode238throw new Error("Unknown line "+(i+1)+" "+JSON.stringify(j));i++}}}239// Parses the --- and +++ headers, if none are found, no lines240// are consumed.241function c(a){var b=/^(---|\+\+\+)\s+([\S ]*)(?:\t(.*?)\s*)?$/,c=b.exec(f[i]);if(c){var d="---"===c[1]?"old":"new";a[d+"FileName"]=c[2],a[d+"Header"]=c[3],i++}}242// Parses a hunk243// This assumes that we are at the start of a hunk.244function d(){for(var a=i,b=f[i++],c=b.split(/@@ -(\d+)(?:,(\d+))? \+(\d+)(?:,(\d+))? @@/),d={oldStart:+c[1],oldLines:+c[2]||1,newStart:+c[3],newLines:+c[4]||1,lines:[],linedelimiters:[]},h=0,j=0;i<f.length&&!(0===f[i].indexOf("--- ")&&i+2<f.length&&0===f[i+1].indexOf("+++ ")&&0===f[i+2].indexOf("@@"));i++){var k=f[i][0];if("+"!==k&&"-"!==k&&" "!==k&&"\\"!==k)break;d.lines.push(f[i]),d.linedelimiters.push(g[i]||"\n"),"+"===k?h++:"-"===k?j++:" "===k&&(h++,j++)}245// Perform optional sanity checking246if(247// Handle the empty block count case248h||1!==d.newLines||(d.newLines=0),j||1!==d.oldLines||(d.oldLines=0),e.strict){if(h!==d.newLines)throw new Error("Added line count did not match for hunk at line "+(a+1));if(j!==d.oldLines)throw new Error("Removed line count did not match for hunk at line "+(a+1))}return d}for(/*istanbul ignore start*/249var/*istanbul ignore end*/e=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],f=a.split(/\r\n|[\n\v\f\r\x85]/),g=a.match(/\r\n|[\n\v\f\r\x85]/g)||[],h=[],i=0;i<f.length;)b();return h}b.__esModule=!0,b.parsePatch=c},/* 12 */250/***/251function(a,b){/*istanbul ignore start*/252"use strict";b.__esModule=!0,b["default"]=/*istanbul ignore end*/function(a,b,c){var d=!0,e=!1,f=!1,g=1;return function h(){if(d&&!f){253// Check if trying to fit beyond text length, and if not, check it fits254// after offset location (or desired location on first iteration)255if(e?g++:d=!1,a+g<=c)return g;f=!0}if(!e)256// Check if trying to fit before text beginning, and if not, check it fits257// before offset location258// Check if trying to fit before text beginning, and if not, check it fits259// before offset location260return f||(d=!0),b<=a-g?-g++:(e=!0,h())}}},/* 13 */261/***/262function(a,b,c){/*istanbul ignore start*/263"use strict";/*istanbul ignore start*/264function d(a){if(Array.isArray(a)){for(var b=0,c=Array(a.length);b<a.length;b++)c[b]=a[b];return c}return Array.from(a)}/*istanbul ignore end*/265function e(a,b,c,e,f,g,i){// Append an empty value to make cleanup easier266function j(a){return a.map(function(a){return" "+a})}i||(i={}),"undefined"==typeof i.context&&(i.context=4);var k=/*istanbul ignore start*/(0,h.diffLines)(c,e,i);k.push({value:"",lines:[]});for(var l=[],m=0,n=0,o=[],p=1,q=1,r=function(/*istanbul ignore end*/a){var b=k[a],f=b.lines||b.value.replace(/\n$/,"").split("\n");if(b.lines=f,b.added||b.removed){/*istanbul ignore start*/267var g;/*istanbul ignore end*/268// If we have previous context, start with that269if(!m){var h=k[a-1];m=p,n=q,h&&(o=i.context>0?j(h.lines.slice(-i.context)):[],m-=o.length,n-=o.length)}270// Output our changes271/*istanbul ignore start*/272(g=/*istanbul ignore end*/o).push.apply(/*istanbul ignore start*/g,/*istanbul ignore start*/d(/*istanbul ignore end*/f.map(function(a){return(b.added?"+":"-")+a}))),273// Track the updated file position274b.added?q+=f.length:p+=f.length}else{275// Identical context lines. Track line changes276if(m)277// Close out any changes that have been output (or join overlapping)278if(f.length<=2*i.context&&a<k.length-2){/*istanbul ignore start*/279var r;/*istanbul ignore end*/280// Overlapping281/*istanbul ignore start*/282(r=/*istanbul ignore end*/o).push.apply(/*istanbul ignore start*/r,/*istanbul ignore start*/d(/*istanbul ignore end*/j(f)))}else{/*istanbul ignore start*/283var s,t=Math.min(f.length,i.context);/*istanbul ignore start*/284(s=/*istanbul ignore end*/o).push.apply(/*istanbul ignore start*/s,/*istanbul ignore start*/d(/*istanbul ignore end*/j(f.slice(0,t))));var u={oldStart:m,oldLines:p-m+t,newStart:n,newLines:q-n+t,lines:o};if(a>=k.length-2&&f.length<=i.context){285// EOF is inside this hunk286var v=/\n$/.test(c),w=/\n$/.test(e);0!=f.length||v?v&&w||o.push("\\ No newline at end of file"):287// special case: old has no eol and no trailing context; no-nl can end up before adds288o.splice(u.oldLines,0,"\\ No newline at end of file")}l.push(u),m=0,n=0,o=[]}p+=f.length,q+=f.length}},s=0;s<k.length;s++)/*istanbul ignore start*/289r(/*istanbul ignore end*/s);return{oldFileName:a,newFileName:b,oldHeader:f,newHeader:g,hunks:l}}function f(a,b,c,d,f,g,h){var i=e(a,b,c,d,f,g,h),j=[];a==b&&j.push("Index: "+a),j.push("==================================================================="),j.push("--- "+i.oldFileName+("undefined"==typeof i.oldHeader?"":"\t"+i.oldHeader)),j.push("+++ "+i.newFileName+("undefined"==typeof i.newHeader?"":"\t"+i.newHeader));for(var k=0;k<i.hunks.length;k++){var l=i.hunks[k];j.push("@@ -"+l.oldStart+","+l.oldLines+" +"+l.newStart+","+l.newLines+" @@"),j.push.apply(j,l.lines)}return j.join("\n")+"\n"}function g(a,b,c,d,e,g){return f(a,a,b,c,d,e,g)}b.__esModule=!0,b.structuredPatch=e,/*istanbul ignore start*/290b.createTwoFilesPatch=f,/*istanbul ignore start*/291b.createPatch=g;var/*istanbul ignore start*/h=c(5)},/* 14 */292/***/293function(a,b){/*istanbul ignore start*/294"use strict";295// See: http://code.google.com/p/google-diff-match-patch/wiki/API296function c(a){for(var b=[],c=/*istanbul ignore start*/void 0,d=/*istanbul ignore start*/void 0,e=0;e<a.length;e++)c=a[e],d=c.added?1:c.removed?-1:0,b.push([d,c.value]);return b}b.__esModule=!0,b.convertChangesToDMP=c},/* 15 */297/***/298function(a,b){/*istanbul ignore start*/...

Full Screen

Full Screen

smartReplace.js

Source:smartReplace.js Github

copy

Full Screen

1const axios = require("axios");2const fs = require("fs");3const replacements = [];4var remoteContent;5async function init(content) {6 remoteContent = content;7 await inject();8 return batchReplace(remoteContent);9}10//#region 注入代码11async function inject() {12 await inject_jd();13}14async function inject_jd() {15 if (!process.env.JD_COOKIE) return;16 if (remoteContent.indexOf("function requireConfig()") >= 0 && remoteContent.indexOf("jd_bean_sign.js") >= 0) {17 replacements.push({18 key: "resultPath = err ? '/tmp/result.txt' : resultPath;",19 value: `resultPath = err ? './tmp/result.txt' : resultPath;`,20 });21 replacements.push({22 key: "JD_DailyBonusPath = err ? '/tmp/JD_DailyBonus.js' : JD_DailyBonusPath;",23 value: `JD_DailyBonusPath = err ? './tmp/JD_DailyBonus.js' : JD_DailyBonusPath;`,24 });25 replacements.push({26 key: "outPutUrl = err ? '/tmp/' : outPutUrl;",27 value: `outPutUrl = err ? './tmp/' : outPutUrl;`,28 });29 }30 ignore_jd();31 await downloader_jd();32 await downloader_notify();33 await downloader_user_agents();34}35function ignore_jd() {36 // 京喜农场禁用部分Cookie,以避免被频繁通知需要去种植啥的37 if (process.env.IGNORE_COOKIE_JXNC) {38 try {39 var ignore_indexs = JSON.parse(process.env.IGNORE_COOKIE_JXNC);40 var ignore_names = [];41 ignore_indexs.forEach((it) => {42 if (it == 1) {43 ignore_names.push("CookieJD");44 } else {45 ignore_names.push("CookieJD" + it);46 }47 });48 replacements.push({49 key: "if (jdCookieNode[item]) {",50 value: `if (jdCookieNode[item] && ${JSON.stringify(ignore_names)}.indexOf(item) == -1) {`,51 });52 console.log(`IGNORE_COOKIE_JXNC已生效,将为您禁用${ignore_names}`);53 } catch (e) {54 console.log("IGNORE_COOKIE_JXNC填写有误,不禁用任何Cookie");55 }56 }57 // 京喜工厂禁用部分Cookie,以避免被频繁通知需要去种植啥的58 if (process.env.IGNORE_COOKIE_JXGC) {59 try {60 var ignore_indexs = JSON.parse(process.env.IGNORE_COOKIE_JXGC);61 var ignore_names = [];62 ignore_indexs.forEach((it) => {63 if (it == 1) {64 ignore_names.push("CookieJD");65 } else {66 ignore_names.push("CookieJD" + it);67 }68 });69 replacements.push({70 key: "cookiesArr.push(jdCookieNode[item])",71 value: `if (jdCookieNode[item] && ${JSON.stringify(72 ignore_names73 )}.indexOf(item) == -1) cookiesArr.push(jdCookieNode[item])`,74 });75 console.log(`IGNORE_COOKIE_JXNC已生效,将为您禁用${ignore_names}`);76 } catch (e) {77 console.log("IGNORE_COOKIE_JXNC填写有误,不禁用任何Cookie");78 }79 }80 // 口袋书店禁用部分Cookie81 if (process.env.IGNORE_COOKIE_BOOKSHOP) {82 try {83 var ignore_indexs = JSON.parse(process.env.IGNORE_COOKIE_BOOKSHOP);84 var ignore_names = [];85 ignore_indexs.forEach((it) => {86 if (it == 1) {87 ignore_names.push("CookieJD");88 } else {89 ignore_names.push("CookieJD" + it);90 }91 });92 replacements.push({93 key: "cookiesArr.push(jdCookieNode[item])",94 value: `if (jdCookieNode[item] && ${JSON.stringify(95 ignore_names96 )}.indexOf(item) == -1) cookiesArr.push(jdCookieNode[item])`,97 });98 console.log(`IGNORE_COOKIE_BOOKSHOP已生效,将为您禁用${ignore_names}`);99 } catch (e) {100 console.log("IGNORE_COOKIE_BOOKSHOP填写有误,不禁用任何Cookie");101 }102 }103 // 京东农场禁用部分Cookie104 if (process.env.IGNORE_COOKIE_JDNC) {105 try {106 var ignore_indexs = JSON.parse(process.env.IGNORE_COOKIE_JDNC);107 var ignore_names = [];108 ignore_indexs.forEach((it) => {109 if (it == 1) {110 ignore_names.push("CookieJD");111 } else {112 ignore_names.push("CookieJD" + it);113 }114 });115 replacements.push({116 key: "cookiesArr.push(jdCookieNode[item])",117 value: `if (jdCookieNode[item] && ${JSON.stringify(118 ignore_names119 )}.indexOf(item) == -1) cookiesArr.push(jdCookieNode[item])`,120 });121 console.log(`IGNORE_COOKIE_JDNC已生效,将为您禁用${ignore_names}`);122 } catch (e) {123 console.log("IGNORE_COOKIE_JDNC填写有误,不禁用任何Cookie");124 }125 }126 // 京东工厂禁用部分Cookie127 if (process.env.IGNORE_COOKIE_JDGC) {128 try {129 var ignore_indexs = JSON.parse(process.env.IGNORE_COOKIE_JDGC);130 var ignore_names = [];131 ignore_indexs.forEach((it) => {132 if (it == 1) {133 ignore_names.push("CookieJD");134 } else {135 ignore_names.push("CookieJD" + it);136 }137 });138 replacements.push({139 key: "cookiesArr.push(jdCookieNode[item])",140 value: `if (jdCookieNode[item] && ${JSON.stringify(141 ignore_names142 )}.indexOf(item) == -1) cookiesArr.push(jdCookieNode[item])`,143 });144 console.log(`IGNORE_COOKIE_JDGC已生效,将为您禁用${ignore_names}`);145 } catch (e) {146 console.log("IGNORE_COOKIE_JDGC填写有误,不禁用任何Cookie");147 }148 }149}150function batchReplace() {151 for (var i = 0; i < replacements.length; i++) {152 remoteContent = remoteContent.replace(replacements[i].key, replacements[i].value);153 }154 // console.log(remoteContent);155 return remoteContent;156}157//#endregion158//#region 文件下载159async function downloader_jd() {160 if (/require\(['"`]{1}.\/jdCookie.js['"`]{1}\)/.test(remoteContent))161 await download("https://github.com/lxk0301/jd_scripts/raw/master/jdCookie.js", "./jdCookie.js", "京东Cookies");162 if (remoteContent.indexOf("jdFruitShareCodes") > 0) {163 await download(164 "https://github.com/lxk0301/jd_scripts/raw/master/jdFruitShareCodes.js",165 "./jdFruitShareCodes.js",166 "东东农场互助码"167 );168 }169 if (remoteContent.indexOf("jdPetShareCodes") > 0) {170 await download(171 "https://github.com/lxk0301/jd_scripts/raw/master/jdPetShareCodes.js",172 "./jdPetShareCodes.js",173 "京东萌宠"174 );175 }176 if (remoteContent.indexOf("jdPlantBeanShareCodes") > 0) {177 await download(178 "https://github.com/lxk0301/jd_scripts/raw/master/jdPlantBeanShareCodes.js",179 "./jdPlantBeanShareCodes.js",180 "种豆得豆互助码"181 );182 }183 if (remoteContent.indexOf("jdSuperMarketShareCodes") > 0)184 await download(185 "https://github.com/lxk0301/jd_scripts/raw/master/jdSuperMarketShareCodes.js",186 "./jdSuperMarketShareCodes.js",187 "京小超互助码"188 );189 if (remoteContent.indexOf("jdFactoryShareCodes") > 0) {190 await download(191 "https://github.com/lxk0301/jd_scripts/raw/master/jdFactoryShareCodes.js",192 "./jdFactoryShareCodes.js",193 "东东工厂互助码"194 );195 }196 if (remoteContent.indexOf("jdDreamFactoryShareCodes") > 0) {197 await download(198 "https://github.com/lxk0301/jd_scripts/raw/master/jdDreamFactoryShareCodes.js",199 "./jdDreamFactoryShareCodes.js",200 "京喜工厂互助码"201 );202 }203 if (remoteContent.indexOf("new Env('京喜农场')") > 0) {204 await download(205 "https://github.com/lxk0301/jd_scripts/raw/master/jdJxncTokens.js",206 "./jdJxncTokens.js",207 "京喜农场Token"208 );209 await download(210 "https://github.com/lxk0301/jd_scripts/raw/master/jdJxncShareCodes.js",211 "./jdJxncShareCodes.js",212 "京喜农场分享码"213 );214 await download(215 "https://github.com/lxk0301/jd_scripts/raw/master/USER_AGENTS.js",216 "./USER_AGENTS.js",217 "USER_AGENTS"218 );219 }220}221async function downloader_notify() {222 await download("https://github.com/lxk0301/jd_scripts/raw/master/sendNotify.js", "./sendNotify.js", "统一通知");223}224async function downloader_user_agents() {225 await download("https://github.com/lxk0301/jd_scripts/raw/master/USER_AGENTS.js", "./USER_AGENTS.js", "云端UA");226}227async function download(url, path, target) {228 let response = await axios.get(url);229 let fcontent = response.data;230 await fs.writeFileSync(path, fcontent, "utf8");231 console.log(`下载${target}完毕`);232}233//#endregion234module.exports = {235 inject: init,...

Full Screen

Full Screen

SemanticPage.designtime.js

Source:SemanticPage.designtime.js Github

copy

Full Screen

1/*!2 * ${copyright}3 */4// Provides the Design Time Metadata for the sap.f.semantic.SemanticPage control5sap.ui.define([],6 function() {7 "use strict";8 var fnShouldIgnoreSingleAggregation = function (oControl, sAggregationGetter) {9 return !(oControl &&10 oControl[sAggregationGetter] &&11 oControl[sAggregationGetter]() &&12 oControl[sAggregationGetter]().getDomRef());13 };14 var fnIgnoreTitleActionsAggregation = function (oControl, sAggregationGetter) {15 var $ControlDomRef;16 if (!oControl) {17 return true;18 }19 $ControlDomRef = oControl.$().find("sapFDynamicPageTitleActionsBar");20 return !!($ControlDomRef.length > 0 && oControl[sAggregationGetter]().length > 0);21 };22 return {23 aggregations : {24 titleHeading : {25 domRef : function (oControl) {26 return oControl.getTitleHeading().getDomRef();27 },28 ignore : function (oControl) {29 return fnShouldIgnoreSingleAggregation(oControl, "getTitleHeading");30 }31 },32 titleSnappedHeading : {33 domRef : function (oControl) {34 return oControl.getTitleHeading().getDomRef();35 },36 ignore : function (oControl) {37 return fnShouldIgnoreSingleAggregation(oControl, "getTitleSnappedHeading");38 }39 },40 titleExpandedHeading : {41 domRef : function (oControl) {42 return oControl.getTitleHeading().getDomRef();43 },44 ignore : function (oControl) {45 return fnShouldIgnoreSingleAggregation(oControl, "getTitleExpandedHeading");46 }47 },48 titleBreadcrumbs : {49 domRef : function (oControl) {50 return oControl.getTitleBreadcrumbs().getDomRef();51 },52 ignore : function (oControl) {53 return fnShouldIgnoreSingleAggregation(oControl, "getTitleBreadcrumbs");54 }55 },56 titleSnappedContent : {57 domRef : ":sap-domref .sapFDynamicPageTitleMainSnapContentVisible",58 actions : {59 move : {60 changeType: "moveControls"61 }62 },63 ignore : function (oControl) {64 return !!(!oControl || oControl.getTitleSnappedContent().length === 0 || oControl.getHeaderExpanded());65 }66 },67 titleExpandedContent : {68 domRef : ":sap-domref .sapFDynamicPageTitleMainExpandContentVisible",69 actions : {70 move : {71 changeType: "moveControls"72 }73 },74 ignore : function (oControl) {75 return !!(!oControl || oControl.getTitleExpandedContent().length === 0 || !oControl.getHeaderExpanded());76 }77 },78 titleContent : {79 domRef : ":sap-domref .sapFDynamicPageTitleMain > .sapFDynamicPageTitleMainInner > .sapFDynamicPageTitleMainContent",80 actions: {81 move: {82 changeType: "moveControls"83 }84 },85 ignore : function (oControl) {86 return !!(!oControl || oControl.getTitleContent().length === 0);87 }88 },89 titleMainAction : {90 domRef : function (oControl) {91 return oControl.getTitleMainAction().getDomRef();92 },93 ignore : function (oControl) {94 return fnShouldIgnoreSingleAggregation(oControl, "getTitleMainAction");95 }96 },97 editAction : {98 domRef : function (oControl) {99 return oControl.getEditAction().getDomRef();100 },101 ignore : function (oControl) {102 return fnShouldIgnoreSingleAggregation(oControl, "getEditAction");103 }104 },105 addAction : {106 domRef : function (oControl) {107 return oControl.getAddAction().getDomRef();108 },109 ignore : function (oControl) {110 return fnShouldIgnoreSingleAggregation(oControl, "getAddAction");111 }112 },113 deleteAction : {114 domRef : function (oControl) {115 return oControl.getDeleteAction().getDomRef();116 },117 ignore : function (oControl) {118 return fnShouldIgnoreSingleAggregation(oControl, "getDeleteAction");119 }120 },121 copyAction : {122 domRef : function (oControl) {123 return oControl.getCopyAction().getDomRef();124 },125 ignore : function (oControl) {126 return fnShouldIgnoreSingleAggregation(oControl, "getCopyAction");127 }128 },129 flagAction : {130 domRef : function (oControl) {131 return oControl.getFlagAction().getDomRef();132 },133 ignore : function (oControl) {134 return fnShouldIgnoreSingleAggregation(oControl, "getFlagAction");135 }136 },137 favoriteAction : {138 domRef : function (oControl) {139 return oControl.getFavoriteAction().getDomRef();140 },141 ignore : function (oControl) {142 return fnShouldIgnoreSingleAggregation(oControl, "getFavoriteAction");143 }144 },145 fullScreenAction : {146 domRef : function (oControl) {147 return oControl.getFullScreenAction().getDomRef();148 },149 ignore : function (oControl) {150 return fnShouldIgnoreSingleAggregation(oControl, "getFullScreenAction");151 }152 },153 exitFullScreenAction : {154 domRef : function (oControl) {155 return oControl.getExitFullScreenAction().getDomRef();156 },157 ignore : function (oControl) {158 return fnShouldIgnoreSingleAggregation(oControl, "getExitFullScreenAction");159 }160 },161 closeAction : {162 domRef : function (oControl) {163 return oControl.getCloseAction().getDomRef();164 },165 ignore : function (oControl) {166 return fnShouldIgnoreSingleAggregation(oControl, "getCloseAction");167 }168 },169 titleCustomTextActions: {170 domRef : ":sap-domref .sapFDynamicPageTitleActionsBar",171 ignore : function (oControl) {172 return fnIgnoreTitleActionsAggregation(oControl, "getTitleCustomTextActions");173 }174 },175 titleCustomIconActions : {176 domRef : ":sap-domref .sapFDynamicPageTitleActionsBar",177 ignore : function (oControl) {178 return fnIgnoreTitleActionsAggregation(oControl, "getTitleCustomIconActions");179 }180 },181 headerContent : {182 domRef : ":sap-domref .sapFDynamicPageHeaderContent",183 actions : {184 move : {185 changeType: "moveControls"186 }187 },188 ignore : function (oControl) {189 return !(oControl && oControl.getHeaderContent().length > 0);190 }191 },192 content : {193 domRef : ":sap-domref .sapFDynamicPageContent",194 ignore : function (oControl) {195 return fnShouldIgnoreSingleAggregation(oControl, "getContent");196 }197 },198 footerMainAction : {199 domRef : function (oControl) {200 return oControl.getFooterMainAction().getDomRef();201 },202 ignore : function (oControl) {203 return fnShouldIgnoreSingleAggregation(oControl, "getFooterMainAction");204 }205 },206 messagesIndicator : {207 domRef : function (oControl) {208 return oControl.getMessagesIndicator().getDomRef();209 },210 ignore : function (oControl) {211 return fnShouldIgnoreSingleAggregation(oControl, "getMessagesIndicator");212 }213 },214 draftIndicator : {215 domRef : function (oControl) {216 return oControl.getDraftIndicator().getDomRef();217 },218 ignore : function (oControl) {219 return fnShouldIgnoreSingleAggregation(oControl, "getDraftIndicator");220 }221 },222 positiveAction : {223 domRef : function (oControl) {224 return oControl.getPositiveAction().getDomRef();225 },226 ignore : function (oControl) {227 return fnShouldIgnoreSingleAggregation(oControl, "getPositiveAction");228 }229 },230 negativeAction : {231 domRef : function (oControl) {232 return oControl.getNegativeAction().getDomRef();233 },234 ignore : function (oControl) {235 return fnShouldIgnoreSingleAggregation(oControl, "getNegativeAction");236 }237 },238 footerCustomActions : {239 domRef : ":sap-domref .sapFDynamicPageActualFooterControl",240 ignore : function (oControl) {241 return !(oControl &&242 oControl.getFooterCustomActions() &&243 oControl.getFooterCustomActions().length > 0);244 }245 },246 discussInJamAction : {247 domRef : function (oControl) {248 return oControl.getDiscussInJamAction().getDomRef();249 },250 ignore : function (oControl) {251 return fnShouldIgnoreSingleAggregation(oControl, "getDiscussInJamAction");252 }253 },254 saveAsTileAction : {255 domRef : function (oControl) {256 return oControl.getSaveAsTileAction().getDomRef();257 },258 ignore : function (oControl) {259 return fnShouldIgnoreSingleAggregation(oControl, "getSaveAsTileAction");260 }261 },262 shareInJamAction : {263 domRef : function (oControl) {264 return oControl.getShareInJamAction().getDomRef();265 },266 ignore : function (oControl) {267 return fnShouldIgnoreSingleAggregation(oControl, "getShareInJamAction");268 }269 },270 sendMessageAction : {271 domRef : function (oControl) {272 return oControl.getSendMessageAction().getDomRef();273 },274 ignore : function (oControl) {275 return fnShouldIgnoreSingleAggregation(oControl, "getSendMessageAction");276 }277 },278 sendEmailAction : {279 domRef : function (oControl) {280 return oControl.getSendEmailAction().getDomRef();281 },282 ignore : function (oControl) {283 return fnShouldIgnoreSingleAggregation(oControl, "getSendEmailAction");284 }285 },286 printAction : {287 domRef : function (oControl) {288 return oControl.getPrintAction().getDomRef();289 },290 ignore : function (oControl) {291 return fnShouldIgnoreSingleAggregation(oControl, "getPrintAction");292 }293 },294 customShareActions : {295 domRef : function (oControl) {296 return oControl._getActionSheet().getDomRef();297 },298 ignore : function (oControl) {299 // in this case we can reuse the function here300 return fnShouldIgnoreSingleAggregation(oControl, "_getActionSheet");301 }302 }303 },304 scrollContainers : [{305 domRef : ":sap-domref .sapFDynamicPageContentWrapper",306 aggregations : ["headerContent", "content"]307 },308 {309 domRef : function(oElement) {310 return oElement.$("vertSB-sb").get(0);311 }312 }],313 templates: {314 create: "sap/f/designtime/SemanticPage.create.fragment.xml"315 }316 };...

Full Screen

Full Screen

ignore.js

Source:ignore.js Github

copy

Full Screen

1/* automatically generated by JSCoverage - do not edit */2if (! top._$jscoverage) {3 top._$jscoverage = {};4}5var _$jscoverage = top._$jscoverage;6if (! _$jscoverage['ignore.js']) {7 _$jscoverage['ignore.js'] = [];8 _$jscoverage['ignore.js'][1] = 0;9 _$jscoverage['ignore.js'][3] = 0;10 _$jscoverage['ignore.js'][4] = 0;11 _$jscoverage['ignore.js'][6] = 0;12 _$jscoverage['ignore.js'][7] = 0;13 _$jscoverage['ignore.js'][10] = 0;14 _$jscoverage['ignore.js'][14] = 0;15 _$jscoverage['ignore.js'][16] = 0;16 _$jscoverage['ignore.js'][17] = 0;17 _$jscoverage['ignore.js'][22] = 0;18 _$jscoverage['ignore.js'][23] = 0;19 _$jscoverage['ignore.js'][27] = 0;20 _$jscoverage['ignore.js'][32] = 0;21 _$jscoverage['ignore.js'][34] = 0;22 _$jscoverage['ignore.js'][35] = 0;23 _$jscoverage['ignore.js'][37] = 0;24 _$jscoverage['ignore.js'][38] = 0;25 _$jscoverage['ignore.js'][42] = 0;26 _$jscoverage['ignore.js'][43] = 0;27 _$jscoverage['ignore.js'][44] = 0;28}29_$jscoverage['ignore.js'].conditionals = [];30_$jscoverage['ignore.js'][1]++;31function createRequest() {32 _$jscoverage['ignore.js'][3]++;33 if (window.XMLHttpRequest) {34 _$jscoverage['ignore.js'].conditionals[6] = 11;35 _$jscoverage['ignore.js'][4]++;36 return new XMLHttpRequest();37 }38 else {39 _$jscoverage['ignore.js'].conditionals[4] = 5;40 _$jscoverage['ignore.js'][6]++;41 if (window.ActiveXObject) {42 _$jscoverage['ignore.js'].conditionals[9] = 11;43 _$jscoverage['ignore.js'][7]++;44 return new ActiveXObject("Msxml2.XMLHTTP");45 }46 else {47 _$jscoverage['ignore.js'].conditionals[7] = 8;48 _$jscoverage['ignore.js'][10]++;49 throw "no XMLHttpRequest implementation available";50 }51 }52}53_$jscoverage['ignore.js'][14]++;54function createRequest2() {55 _$jscoverage['ignore.js'][16]++;56 if (window.XMLHttpRequest) {57 _$jscoverage['ignore.js'][17]++;58 return new XMLHttpRequest();59 }60 else {61 _$jscoverage['ignore.js'].conditionals[17] = 18;62 }63 _$jscoverage['ignore.js'][22]++;64 if (window.ActiveXObject) {65 _$jscoverage['ignore.js'][23]++;66 return new ActiveXObject("Msxml2.XMLHTTP");67 }68 else {69 _$jscoverage['ignore.js'].conditionals[23] = 24;70 }71 _$jscoverage['ignore.js'][27]++;72 throw "no XMLHttpRequest implementation available";73}74_$jscoverage['ignore.js'][32]++;75function log(s) {76 _$jscoverage['ignore.js'][34]++;77 if (window.console && window.console.log) {78 _$jscoverage['ignore.js'].conditionals[37] = 39;79 _$jscoverage['ignore.js'][35]++;80 console.log(s);81 }82 else {83 _$jscoverage['ignore.js'].conditionals[35] = 36;84 _$jscoverage['ignore.js'][37]++;85 if (window.opera && window.opera.postError) {86 _$jscoverage['ignore.js'][38]++;87 opera.postError(s);88 }89 else {90 _$jscoverage['ignore.js'].conditionals[38] = 39;91 }92 }93}94_$jscoverage['ignore.js'][42]++;95var request = createRequest();96_$jscoverage['ignore.js'][43]++;97var request2 = createRequest2();98_$jscoverage['ignore.js'][44]++;99log("created requests");100if (!( 0)) {101 _$jscoverage['ignore.js'].conditionals[26] = 28;102}103if (!( ! window.XMLHttpRequest)) {104 _$jscoverage['ignore.js'].conditionals[20] = 29;105}...

Full Screen

Full Screen

loginCGCS.frag

Source:loginCGCS.frag Github

copy

Full Screen

1PASS2# not used for now3PROMPT (.*:~#\s)(.*:~\$)|(.*\]:\s)|(.*\)\]#\s)|(.*\]#\s)|(.*\)\]\$\s)4Con1 PROMPT (.*:~#\s)(.*:~\$)|(.*\]:\s)|(.*\)\]#\s)|(.*\]#\s)|(.*\)\]\$\s)5Con2 PROMPT (.*:~#\s)(.*:~\$)|(.*\]:\s)|(.*\)\]#\s)|(.*\]#\s)|(.*\)\]\$\s)6Com1 PROMPT (.*:~#\s)(.*:~\$)|(.*\]:\s)|(.*\)\]#\s)|(.*\]#\s)|(.*\)\]\$\s)7Com2 PROMPT (.*:~#\s)(.*:~\$)|(.*\]:\s)|(.*\)\]#\s)|(.*\]#\s)|(.*\)\]\$\s)8TYPE \n9WAIT 5 SEC {ignoreTimeout:True} login:10TYPE ${WRSUSER}\n11WAIT 5 SEC {ignoreTimeout:True} assword: 12TYPE ${WRSPASS}\n13WAIT 5 SEC {ignoreTimeout:True} .*\s 14TYPE source /etc/nova/openrc\n15WAIT 5 SEC {ignoreTimeout:True} .*\s 16TYPE export TMOUT=0\n17WAIT 5 SEC {ignoreTimeout:True} .*\s 18Con2 TYPE \n19Con2 WAIT 1 SEC {ignoreTimeout:True} login:20Con2 TYPE ${WRSUSER}\n21Con2 WAIT 1 SEC {ignoreTimeout:True} assword:22Con2 TYPE ${WRSPASS}\n23Con2 WAIT 1 SEC {ignoreTimeout:True} .*\s24Con2 TYPE source /etc/nova/openrc\n25Con2 WAIT 1 SEC {ignoreTimeout:True} .*\s26TYPE export TMOUT=0\n27WAIT 1 SEC {ignoreTimeout:True} .*\s 28Com1 TYPE \n29Com1 WAIT 1 SEC {ignoreTimeout:True} login:30Com1 TYPE ${WRSUSER}\n31Com1 WAIT 1 SEC {ignoreTimeout:True} assword:32Com1 TYPE ${WRSPASS}\n33Com1 WAIT 1 SEC {ignoreTimeout:True} .*\s34Com1 TYPE source /etc/nova/openrc\n35Com1 WAIT 1 SEC {ignoreTimeout:True} .*\s36TYPE export TMOUT=0\n37WAIT 1 SEC {ignoreTimeout:True} .*\s 38Com2 TYPE \n39Com2 WAIT 1 SEC {ignoreTimeout:True} login:40Com2 TYPE ${WRSUSER}\n41Com2 WAIT 1 SEC {ignoreTimeout:True} assword:42Com2 TYPE ${WRSPASS}\n43Com2 WAIT 1 SEC {ignoreTimeout:True} .*\s44Com2 TYPE source /etc/nova/openrc\n45Com2 WAIT 1 SEC {ignoreTimeout:True} .*\s46TYPE export TMOUT=0\n47WAIT 1 SEC {ignoreTimeout:True} .*\s ...

Full Screen

Full Screen

docgen-ignore-before-comment.js

Source:docgen-ignore-before-comment.js Github

copy

Full Screen

1'use strict';2const rule = require('../../../lib/rules/docgen-ignore-before-comment');3const RuleTester = require('eslint').RuleTester;4const ruleTester = new RuleTester();5ruleTester.run('ignore-before-comment', rule, {6 valid: [7 '\n/**\n * @ignore\n */\n',8 '\n/**\n * @ignore\n * Comment.\n */\n',9 '\n/**\n * @ignore\n * Multi-line\n * comment.\n */\n',10 '\n /**\n * @ignore\n * Indented\n * multi-line\n * comment.\n */\n',11 ],12 invalid: [13 {14 code: '\n/**\n * Comment.\n * @ignore\n */\n',15 errors: [{message: '@ignore should be at the beginning of a block comment.', type: 'Block'}],16 },17 {18 code: '\n /**\n * Multi-line\n * comment.\n * @ignore\n */\n',19 errors: [{message: '@ignore should be at the beginning of a block comment.', type: 'Block'}],20 },21 {22 code: '\n /**\n * Multi-line\n * @ignore\n * comment.\n */\n',23 errors: [{message: '@ignore should be at the beginning of a block comment.', type: 'Block'}],24 },25 {26 code: '\n /**\n * Indented\n * multi-line\n * comment.\n * @ignore\n */\n',27 errors: [{message: '@ignore should be at the beginning of a block comment.', type: 'Block'}],28 },29 ],...

Full Screen

Full Screen

coercion-ignoreCase.js

Source:coercion-ignoreCase.js Github

copy

Full Screen

1// Copyright (C) 2017 Aleksey Shvayka. All rights reserved.2// This code is governed by the BSD license found in the LICENSE file.3/*---4esid: sec-get-regexp.prototype.flags5description: Boolean coercion of the ignoreCase property6info: >7 get RegExp.prototype.flags8 ...9 6. Let ignoreCase be ToBoolean(? Get(R, "ignoreCase")).10 ...11features: [Symbol]12---*/13var get = Object.getOwnPropertyDescriptor(RegExp.prototype, "flags").get;14var r = {};15r.ignoreCase = undefined;16assert.sameValue(get.call(r), "", "ignoreCase: undefined");17r.ignoreCase = null;18assert.sameValue(get.call(r), "", "ignoreCase: null");19r.ignoreCase = NaN;20assert.sameValue(get.call(r), "", "ignoreCase: NaN");21r.ignoreCase = "";22assert.sameValue(get.call(r), "", "ignoreCase: the empty string");23r.ignoreCase = "string";24assert.sameValue(get.call(r), "i", "ignoreCase: string");25r.ignoreCase = 86;26assert.sameValue(get.call(r), "i", "ignoreCase: 86");27r.ignoreCase = Symbol();28assert.sameValue(get.call(r), "i", "ignoreCase: Symbol()");29r.ignoreCase = [];30assert.sameValue(get.call(r), "i", "ignoreCase: []");31r.ignoreCase = {};32assert.sameValue(get.call(r), "i", "ignoreCase: {}");...

Full Screen

Full Screen

Using AI Code Generation

copy

Full Screen

1var webdriverio = require('webdriverio');2var options = {3 desiredCapabilities: {4 }5};6 .remote(options)7 .init()8 .getTitle().then(function(title) {9 console.log('Title was: ' + title);10 })11 .end();12var webdriverjs = require('webdriverjs');13var client = webdriverjs.remote();14 .init()15 .getTitle(function(err, title) {16 console.log('Title was: ' + title);17 })18 .end();19var webdriver = require('selenium-webdriver');20var driver = new webdriver.Builder()21 .forBrowser('chrome')22 .build();23driver.getTitle().then(function(title) {24 console.log('Title was: ' + title);25});26driver.quit();27var Nightmare = require('nightmare');28var nightmare = Nightmare({ show: true });29 .evaluate(function () {30 return document.title;31 })32 .end()33 .then(function (result) {34 console.log('Title was: ' + result);35 })36 .catch(function (error) {37 console.error('Search failed:', error);38 });39var webdriver = require('selenium-webdriver'),40 until = webdriver.until;41var driver = new webdriver.Builder()42 .forBrowser('chrome')43 .build();44driver.getTitle().then(function(title) {45 console.log('Title was: ' + title);

Full Screen

Using AI Code Generation

copy

Full Screen

1const assert = require('assert');2const { remote } = require('webdriverio');3(async () => {4 const browser = await remote({5 capabilities: {6 }7 })8 await browser.$('#hplogo').waitForExist({ timeout: 5000 })9 const logo = await browser.$('#hplogo').isExisting()10 assert.strictEqual(logo, true)11 await browser.deleteSession()12})().catch((e) => console.error(e))13const assert = require('assert');14const { Builder, By, Key, until } = require('selenium-webdriver');15(async function example() {16 let driver = await new Builder().forBrowser('chrome').build();17 try {18 await driver.findElement(By.id('hplogo')).isDisplayed()19 const logo = await driver.findElement(By.id('hplogo')).isDisplayed()20 assert.strictEqual(logo, true)21 } finally {22 await driver.quit();23 }24})();25 * Additional wdio packages used (if applicable): @wdio/selenium-standalone-service, @wdio/spec-reporter, @wdio/sync

Full Screen

Using AI Code Generation

copy

Full Screen

1const assert = require('assert');2const { remote } = require('webdriverio');3(async () => {4 const browser = await remote({5 capabilities: {6 }7 })8 await browser.pause(3000)9 await browser.execute(function () {10 document.getElementById('lst-ib').value = 'WebdriverIO';11 });12 await browser.pause(3000)13 await browser.execute(function () {14 document.getElementsByName('btnK')[0].click();15 });16 await browser.pause(3000)17 await browser.execute(function () {18 document.getElementById('lst-ib').value = 'WebdriverIO';19 });20 await browser.pause(3000)21 await browser.execute(function () {22 document.getElementsByName('btnK')[0].click();23 });24 await browser.pause(3000)25 await browser.deleteSession();26})().catch((e) => console.error(e))

Full Screen

Using AI Code Generation

copy

Full Screen

1describe('webdriver.io page', () => {2 it('should have the right title', () => {3 browser.ignoreSynchronization = true;4 browser.getTitle().should.be.equal('Google');5 });6});7describe('webdriver.io page', () => {8 it('should have the right title', () => {9 browser.ignoreSynchronization = true;10 browser.waitForExist('#hplogo', 5000);11 browser.getTitle().should.be.equal('Google');12 });13});14describe('webdriver.io page', () => {15 it('should have the right title', () => {16 browser.ignoreSynchronization = true;17 browser.waitForVisible('#hplogo', 5000);18 browser.getTitle().should.be.equal('Google');19 });20});

Full Screen

Using AI Code Generation

copy

Full Screen

1browser.ignoreSynchronization = true;2browser.ignoreSynchronization = false;3browser.ignoreSynchronization = true;4browser.ignoreSynchronization = false;5browser.ignoreSynchronization = true;6browser.ignoreSynchronization = false;7browser.pause(10000);8browser.call(function() {9 console.log('This function will be executed synchronously');10});11browser.call(function() {12 console.log('This function will be executed synchronously');13});14browser.call(function() {15 console.log('This function will be executed synchronously');16});17browser.call(function() {18 console.log('This function will be executed synchronously');19});20browser.call(function() {21 console.log('This function will be executed synchronously');22});23browser.call(function() {24 console.log('This function will be executed synchronously');25});26browser.call(function() {27 console.log('This function will be executed synchronously');28});29browser.call(function() {30 console.log('This function will be executed synchronously');31});32browser.call(function() {33 console.log('This function will be executed synchronously');34});35browser.call(function() {36 console.log('This function will be executed synchronously');37});38browser.call(function() {39 console.log('This function will be executed synchronously');40});41browser.call(function() {42 console.log('This function will be executed synchronously');43});

Full Screen

Using AI Code Generation

copy

Full Screen

1describe('My first test', () => {2 it('should pass', () => {3 const link = $('=Docs');4 link.waitForExist();5 link.click();6 browser.pause(3000);7 browser.back();8 browser.pause(3000);9 browser.forward();10 browser.pause(3000);11 browser.refresh();12 browser.pause(3000);13 browser.pause(3000);14 browser.saveScreenshot('screenshot.png');15 browser.pause(3000);16 browser.saveScreenshot('screenshot1.png');17 browser.pause(3000);18 browser.saveScreenshot('screenshot2.png');19 browser.pause(3000);20 browser.saveScreenshot('screenshot3.png');21 browser.pause(3000);22 browser.saveScreenshot('screenshot4.png');23 browser.pause(3000);24 browser.saveScreenshot('screenshot5.png');25 browser.pause(3000);26 browser.saveScreenshot('screenshot6.png');27 browser.pause(3000);28 browser.saveScreenshot('screenshot7.png');29 browser.pause(3000);30 browser.saveScreenshot('screenshot8.png');31 browser.pause(3000);32 browser.saveScreenshot('screenshot9.png');33 browser.pause(3000);34 browser.saveScreenshot('screenshot10.png');35 browser.pause(3000);36 browser.saveScreenshot('screenshot11.png');37 browser.pause(3000);38 browser.saveScreenshot('screenshot12.png');39 browser.pause(3000);40 browser.saveScreenshot('screenshot13.png');41 browser.pause(3000);42 browser.saveScreenshot('screenshot14.png');43 browser.pause(3000);44 browser.saveScreenshot('screenshot15.png');45 browser.pause(3000);46 browser.saveScreenshot('screenshot16.png');47 browser.pause(3000);48 browser.saveScreenshot('screenshot17.png');49 browser.pause(3000);50 browser.saveScreenshot('screenshot18.png');51 browser.pause(3000);52 browser.saveScreenshot('screenshot19.png');53 browser.pause(3000);54 browser.saveScreenshot('screenshot20.png');55 browser.pause(3000);56 browser.saveScreenshot('screenshot21.png');57 browser.pause(3000);58 browser.saveScreenshot('screenshot22.png');59 browser.pause(3000);60 browser.saveScreenshot('screenshot23

Full Screen

Using AI Code Generation

copy

Full Screen

1describe('Test', () => {2 it('should pass', () => {3 browser.pause(5000);4 });5});6describe('Test', () => {7 it('should pass', () => {8 browser.pause(5000);9 });10});11ignore(methods, callback)12ignore(methods, callback, args)13ignore(methods, args)14ignore(methods, args, callback)15ignore(methods, callback)16browser.ignore('uncaughtException', () => {17 browser.pause(5000);18});19ignore(methods, callback, args)20browser.ignore('uncaughtException', () => {21 browser.pause(5000);22}, true);23ignore(methods, args)24browser.ignore('uncaughtException', true);25ignore(methods, args, callback)26browser.ignore('uncaughtException', true, () => {27 browser.pause(5000);28});

Full Screen

Using AI Code Generation

copy

Full Screen

1const path = require('path');2describe('Test to ignore an element', () => {3 it('should ignore the element', () => {4 browser.pause(2000);5 browser.saveElement($('header'), 'header');6 browser.pause(2000);7 browser.saveElement($('footer'), 'footer');8 browser.pause(2000);9 browser.saveElement($('main'), 'main');10 browser.pause(2000);11 browser.saveElement($('div'), 'div');12 browser.pause(2000);13 browser.saveElement($('html'), 'html');14 browser.pause(2000);15 browser.saveElement($('body'), 'body');16 browser.pause(2000);17 browser.saveElement($('section'), 'section');18 browser.pause(2000);19 browser.saveElement($('p'), 'p');20 browser.pause(2000);21 browser.saveElement($('h1'), 'h1');22 browser.pause(2000);23 browser.saveElement($('h2'), 'h2');24 browser.pause(2000);25 browser.saveElement($('h3'), 'h3');26 browser.pause(2000);27 browser.saveElement($('h4'), 'h4');28 browser.pause(2000);29 browser.saveElement($('h5'), 'h5');30 browser.pause(2000);31 browser.saveElement($('h6'), 'h6');32 browser.pause(2000);33 browser.saveElement($('a'), 'a');34 browser.pause(2000);35 browser.saveElement($('nav'), 'nav');36 browser.pause(2000);37 browser.saveElement($('ul'), 'ul');38 browser.pause(2000);39 browser.saveElement($('ol'), 'ol');40 browser.pause(2000);41 browser.saveElement($('li'), 'li');42 browser.pause(2000);43 browser.saveElement($('button'), 'button');44 browser.pause(2000);45 browser.saveElement($('form'), 'form');46 browser.pause(2000);47 browser.saveElement($('input'), 'input');48 browser.pause(2000);49 browser.saveElement($('textarea'), 'textarea');50 browser.pause(2000);51 browser.saveElement($('select'), 'select');52 browser.pause(2000);53 browser.saveElement($('img'), 'img');54 browser.pause(2000);55 browser.saveElement($('table'), 'table');56 browser.pause(2000

Full Screen

Using AI Code Generation

copy

Full Screen

1it('should ignore a certain element', () => {2 const elem = $('.menu__list')3 elem.scrollIntoView()4 browser.saveElement(elem, 'element')5 browser.checkElement(elem, 'element')6 browser.checkElement(elem, 'element', {ignore: '.menu__list-item'})7})8it('should check a certain element', () => {9 const elem = $('.menu__list')10 elem.scrollIntoView()11 browser.saveElement(elem, 'element')12 browser.checkElement(elem, 'element', {ignore: '.menu__list-item'})13})14it('should check a certain region', () => {15 const elem = $('.menu__list')16 elem.scrollIntoView()17 browser.saveElement(elem, 'element')18 browser.checkRegion(elem, 'element')19})20it('should check full page screen', () => {21 browser.saveFullPageScreen('fullPage', { /* some options */ })22 browser.checkFullPageScreen('fullPage', { /* some options */ })23})24it('should check full page screen', () => {25 browser.saveFullPageScreen('fullP

Full Screen

WebdriverIO Tutorial

Wondering what could be a next-gen browser and mobile test automation framework that is also simple and concise? Yes, that’s right, it's WebdriverIO. Since the setup is very easy to follow compared to Selenium testing configuration, you can configure the features manually thereby being the center of attraction for automation testing. Therefore the testers adopt WedriverIO to fulfill their needs of browser testing.

Learn to run automation testing with WebdriverIO tutorial. Go from a beginner to a professional automation test expert with LambdaTest WebdriverIO tutorial.

Chapters

  1. Running Your First Automation Script - Learn the steps involved to execute your first Test Automation Script using WebdriverIO since the setup is very easy to follow and the features can be configured manually.

  2. Selenium Automation With WebdriverIO - Read more about automation testing with WebdriverIO and how it supports both browsers and mobile devices.

  3. Browser Commands For Selenium Testing - Understand more about the barriers faced while working on your Selenium Automation Scripts in WebdriverIO, the ‘browser’ object and how to use them?

  4. Handling Alerts & Overlay In Selenium - Learn different types of alerts faced during automation, how to handle these alerts and pops and also overlay modal in WebdriverIO.

  5. How To Use Selenium Locators? - Understand how Webdriver uses selenium locators in a most unique way since having to choose web elements very carefully for script execution is very important to get stable test results.

  6. Deep Selectors In Selenium WebdriverIO - The most popular automation testing framework that is extensively adopted by all the testers at a global level is WebdriverIO. Learn how you can use Deep Selectors in Selenium WebdriverIO.

  7. Handling Dropdown In Selenium - Learn more about handling dropdowns and how it's important while performing automated browser testing.

  8. Automated Monkey Testing with Selenium & WebdriverIO - Understand how you can leverage the amazing quality of WebdriverIO along with selenium framework to automate monkey testing of your website or web applications.

  9. JavaScript Testing with Selenium and WebdriverIO - Speed up your Javascript testing with Selenium and WebdriverIO.

  10. Cross Browser Testing With WebdriverIO - Learn more with this step-by-step tutorial about WebdriverIO framework and how cross-browser testing is done with WebdriverIO.

Run Webdriverio automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful