New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

react-building-blocks

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-building-blocks - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

19

dist/components/SidebarModule/SidebarModule.test.js

@@ -30,7 +30,2 @@ 'use strict';

'Some content'
),
_react2.default.createElement(
'p',
null,
'Some more content'
)

@@ -49,15 +44,9 @@ ));

it('renders all children', function () {
expect(renderedDOM().children.length).toEqual(2);
it('renders header', function () {
expect(renderedDOM('Header Text').children[0].tagName).toEqual('H6');
});
it('renders all child content', function () {
expect(renderedDOM().children[0].textContent).toEqual('Some content');
expect(renderedDOM().children[1].textContent).toEqual('Some more content');
it('renders child content', function () {
expect(renderedDOM('Header Text').children[1].tagName).toEqual('P');
});
it('renders a header first if specified', function () {
expect(renderedDOM('Header Text').children[0].tagName).toEqual('H2');
});
});

@@ -39,3 +39,3 @@ 'use strict';

return _react2.default.createElement(
'h2',
'h6',
_extends({ className: ('sidebar-module-header ' + className).trim() }, props),

@@ -42,0 +42,0 @@ children

@@ -32,3 +32,3 @@ 'use strict';

it('renders a header element with the appropriate class name', function () {
expect(renderedDOM().tagName).toEqual('H2');
expect(renderedDOM().tagName).toEqual('H6');

@@ -35,0 +35,0 @@ expect(renderedDOM().className).toEqual('sidebar-module-header');

@@ -8,3 +8,3 @@ {

},
"version": "0.2.0",
"version": "0.2.1",
"scripts": {

@@ -11,0 +11,0 @@ "dev": "cd docs && npm install && open 'http://localhost:8080' && NODE_ENV=development webpack-dev-server --inline --hot",

@@ -10,3 +10,2 @@ import React from 'react';

<p>Some content</p>
<p>Some more content</p>
</SidebarModule>

@@ -24,19 +23,11 @@ );

it('renders all children', () => {
expect(renderedDOM().children.length)
.toEqual(2);
it('renders header', () => {
expect(renderedDOM('Header Text').children[0].tagName)
.toEqual('H6');
});
it('renders all child content', () => {
expect(renderedDOM().children[0].textContent)
.toEqual('Some content');
expect(renderedDOM().children[1].textContent)
.toEqual('Some more content');
it('renders child content', () => {
expect(renderedDOM('Header Text').children[1].tagName)
.toEqual('P');
});
it('renders a header first if specified', () => {
expect(renderedDOM('Header Text').children[0].tagName)
.toEqual('H2');
});
});

@@ -8,5 +8,5 @@ import React, { Component, PropTypes } from 'react';

return (
<h2 className={`sidebar-module-header ${className}`.trim()} {...props}>
<h6 className={`sidebar-module-header ${className}`.trim()} {...props}>
{children}
</h2>
</h6>
);

@@ -13,0 +13,0 @@ }

@@ -12,3 +12,3 @@ import React from 'react';

expect(renderedDOM().tagName)
.toEqual('H2');
.toEqual('H6');

@@ -15,0 +15,0 @@ expect(renderedDOM().className)

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc