teleren/devto huggingface dataset:
Pest 2.0 is now generally available 🐛
Tags: webdev, php, testing
Published: 2023-03-22 09:46:07

[Pest 2.0](https://pestphp.com/) has [just been released](https://pestphp.com/docs/announcing-pest2), and it's here to make your PHP testing experience more enjoyable and efficient. We will dive into the world of Pest and explore what makes it stand out from PHPUnit. Plus, we'll check out the latest features in Pest 2.0! 🚀

## What is Pest? 🤔

Pest is a modern, elegant, and minimalistic PHP testing framework built on top of PHPUnit. It was designed to make testing your PHP code a breeze by offering a more expressive, fun, and readable syntax. 

Pest is fast becoming very popular, and now ships with Laravel, where you can make tests using a `--pest` switch:

```php
php artisan make:test UserTest --pest
```

## Why Pest instead of PHPUnit? 🏆

Now, you might be wondering why you should choose Pest over the more traditional PHPUnit. Here are some key reasons:

1. **Expressive syntax:** Pest's syntax is more human-readable and concise, allowing you to write tests quickly and easily. Say goodbye to long, clunky test names and hello to expressive, straightforward descriptions! 🌟

2. **Better error reporting:** Pest's error reporting is more visually appealing and informative, making it easier for you to understand what went wrong and how to fix it. 🐞

3. **Anonymous functions:** Pest allows you to use anonymous functions for test cases, which reduces boilerplate code and makes your tests more readable. 🍃

4. **Powerful plugins:** Pest offers a growing ecosystem of plugins, giving you even more flexibility and functionality when writing tests. Think of it as an all-you-can-eat buffet of testing goodness! 🍲

## What's new in Pest 2.0? 🎉

Pest 2.0 brings some fantastic new features to the table:

1. **Parallel testing:** Pest 2.0 now supports parallel testing, which means your test suite will run much faster. ⚡

2. **Test case generators:** With test case generators, you can now easily create multiple test cases based on a single test function. This feature helps you reduce code duplication and keep your tests DRY (Don't Repeat Yourself). 🏜️

3. **Improved type hinting:** Pest 2.0 comes with better type hinting, allowing you to enjoy the full benefits of your IDE's autocompletion and error-checking capabilities. 👼

4. **Enhanced performance:** Pest 2.0 boasts improved performance, so you can enjoy faster test execution and a smoother overall experience. 🏎️

## In conclusion 🎈

Pest 2.0 is an exciting update to an already fantastic PHP testing framework. With its expressive syntax, better error reporting, and powerful new features, Pest is an excellent choice for developers looking to make their testing experience more enjoyable and efficient. 😎
ETL Testing Course in chennai
Tags: etl, testing
Published: 2023-03-22 09:15:30

Looking for the best platform to learn [ETL TESTING training in Chennai](https://intellimindz.com/etl-testing-course-in-chennai/) with the latest concepts and techniques? Then, don’t  delay join our ETL Testing Course in Chennai at IntelliMindz where you can learn in-depth about all the techniques and tools that are used in ETL Testing with the real-time projects under the guidance of Real-time professionals. The term ETL means Extract/ Transform/ Load. It refers to the process of verifying, Validating, and Qualifying data while preventing data loss and duplicate records. It is applied to data warehouse systems and used to obtain relevant information for business intelligence and analytics. Most of the compiang in India using evolving  ETL Cloud Technologies. So they are looking for certified ETL Testing Professionals. Looking for theETL TESTING course in Chennai, best platform to learn ETL Testing training in Chennai with the latest concepts and techniques? Then, don’t delay to join our ETL Testing Course in Chennai at IntelliMindz where you can learn in-depth about all the techniques and tools that are used in ETL Testing with real-time projects under the guidance of Real-time professionals. The course curriculum is designed according to the industry standards and trends to help you to get placed in top MNCs with high packages. So, join us now and start your career in the best way. we are providing more course in intellimindz [MSBI training in Chennai](https://intellimindz.com/msbi-training-in-chennai/)  [Android app development course in Chennai](https://intellimindz.com/android-app-development-course-in-chennai/),[Selenium training in Chennai](https://intellimindz.com/selenium-training-in-chennai/), [R Programming training in Chennai](https://intellimindz.com/r-programming-training-in-chennai/), [Sap fico training in Chennai](https://intellimindz.com/sap-fico-training-in-chennai/),  [Azure Online Job support from India](https://onlinejobsupport.net/job-support/microsoft-azure-online-job-support/),[Powerbi Online Job support from India](https://onlinejobsupport.net/job-support/power-bi-online-job-support/).
Mortgage Calculator Java
Tags: mortgagecalculator, javascript, html, beginners
Published: 2023-03-22 09:13:37

Hi All, 

this is my first post and would like to share what I have recently created, I am new to coding and wanted to create a mortgage affordability calculator using HTML, Java and styling with CSS, would love to hear some feedback and would appreciate any suggested improvements I could make. I have embedded this calculator on my website [Mortgage Broker Cardiff](https://www.emwales.com), have a play around and let me know what you think.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ensbjnikpjppcoomtyey.png)

https://github.com/jamalkroll/Mortgagecalc.git
How to Host a Flutter Web App on Microsoft Azure
Published: 2023-03-22 09:08:12

Flutter has become an increasingly popular framework for developing cross-platform mobile applications. In addition to mobile apps, Flutter also supports web app development, enabling developers to create responsive and engaging web experiences. Microsoft Azure is a cloud computing platform that provides various services for hosting, deploying, and managing web applications. In this article, we'll guide you through the process of hosting a Flutter web app on Microsoft Azure.

**Prerequisites**

Before diving into the process, make sure you have the following:

1. A Flutter web app: Create a new Flutter web app or use an existing one.
2. Microsoft Azure account: Sign up for a free trial or use your existing account.
3. Azure CLI: Install the Azure Command-Line Interface (CLI) on your machine.

## Build the Flutter Web App
To deploy the Flutter web app, first, you need to build it for production. Open a terminal and navigate to the root directory of your Flutter project. Run the following command:
`flutter build web`
This command will generate the necessary files for your web app in the build/web directory.

## Set Up a Storage Account on Azure
A Storage Account in Azure is used to store and manage your web app's files. To create a new storage account, follow these steps:

1. Sign in to the [Azure portal](https://portal.azure.com).
2. Click on "Create a resource" in the left sidebar.
3. Search for "Storage Account" and click "Create."
4. Fill in the required fields, such as subscription, resource group, account name, and location. Click "Review + create" and then "Create" to finalize.

## Enable Static Website Hosting
Once your storage account is created, enable static website hosting:
1. Navigate to your storage account in the Azure portal.
2. Click on "Static website" under the "Settings" section.
3. Set "Static website" to "Enabled.".
4. Set "Index document name" to "index.html" and "Error document path" to "404.html."
5. Click "Save."

## Deploy Your Flutter Web App
Now that your storage account is set up and static website hosting is enabled, you can deploy your Flutter web app. First, sign in to Azure CLI using:
`az login`
Once logged in, navigate to the `build/web` directory of your Flutter project and run the following command:
`az storage blob upload-batch -s . -d '$web' --account-name <YourStorageAccountName> --account-key <YourStorageAccountKey>`
Replace `<YourStorageAccountName>` and `<YourStorageAccountKey>` with the appropriate values from your storage account. You can find these in the "Access keys" section of your storage account settings in the Azure portal.

## Access Your Flutter Web App
After deploying your web app, you can access it using the provided URL. In the Azure portal, navigate to your storage account and click on "Static website" under the "Settings" section. You'll see the "Primary endpoint" URL. Open this URL in a web browser to see your Flutter web app in action.
And voila your web app is hosted on Microsoft Azure!
Rust Realtime OTP Algorithm
Tags: rust, algorithms, security, tutorial
Published: 2023-03-22 08:45:45



![OTP illustration](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gmz1xtfzfqrt3q6g5urn.jpg)




## Time-based One-Time Password (TOTP) Algorithm Implementation in Rust

This Rust program provides an implementation of the Time-based One-Time Password (TOTP) algorithm, which is used to generate one-time passwords for multi-factor authentication systems. The algorithm is based on a shared secret and the current time, and produces a 6-digit numerical code that changes every 30 seconds.

## Implementation Details

The core function of the algorithm is `generate_otp(secret: &str)`, which takes a shared secret as input and returns a 6-digit numerical code that changes every 30 seconds. The function uses the following steps to generate the OTP:

1. Get the current time in seconds since the Unix epoch using the `SystemTime` and `UNIX_EPOCH` structs.
2. Divide the current time by 30 to get the current time window.
3. Generate a random number between 0 and 999999 using the `thread_rng()` function from the rand crate.
4. XOR the current time window with the random number to produce an intermediate value.
5. Take the intermediate value mod 1000000 to produce a 6-digit OTP.

## Example Usage

The `main()` function of the program demonstrates how this OTP algorithm can be used in practice, by calling the `generate_otp` function in a loop and printing the resulting OTP to the console every 30 seconds. This simulates the real-time generation of OTPs that would typically be used in multi-factor authentication systems.

```rs
use rand::{Rng, thread_rng};
use std::time::{SystemTime, UNIX_EPOCH};
use std::thread;
use std::time;

fn generate_otp(secret: &str) -> u32 {
    let now = SystemTime::now().duration_since(UNIX_EPOCH).unwrap().as_secs() / 30;
    let mut rng = thread_rng();
    let random_number: u32 = rng.gen_range(0..1000000);
    let otp = (now as u32 ^ random_number) % 1000000;

    otp
}

fn main() {
    let secret = "xxx_Your_Secret_Here_xxx";
    loop {
        let otp = generate_otp(secret);
        println!("Your OTP is: {}", otp);
        thread::sleep(time::Duration::from_secs(30));
    }
}

```

## Security Considerations

Note that the security of the TOTP algorithm depends on the secrecy of the shared secret, which should be kept confidential and not shared with unauthorized users. Additionally, the program should be used in conjunction with appropriate security measures, such as SSL/TLS encryption and strong password policies, to ensure the security of user accounts and sensitive data.

## Additionally 
If you'd like to get a tutorial that includes SSL/TLS please interact or contact me via twitter [@SensoryKopi](https://twitter.com/SensoryKopi)
Preloading Google Fonts
Tags: webdev, css
Published: 2023-03-22 08:22:35

Google Fonts is one of the easiest way to customize your website. Pick your fonts, add few lines of html, and boom, you're done:

```html
<head>
	<link rel="preconnect" href="https://fonts.googleapis.com" crossorigin />
	<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
	<link
		href="https://fonts.googleapis.com/css2?family=Roboto&display=swap"
		rel="stylesheet"
	/>
</head>
```

Well, until you realize that your fonts aren't getting applied immediately, only happening after the whole page has been loaded. That improves page speed but isn't the best design wise (and to some extent, UX wise).

We can tell the browser to load assets before load with `rel="preload"`:

```html
<head>
	<link rel="preconnect" href="https://fonts.googleapis.com" crossorigin />
	<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
	 <link
		href="https://fonts.googleapis.com/css2?family=Roboto&display=swap"
		rel="preload"
		as="style"
		crossorigin
	/>
	<link
		href="https://fonts.googleapis.com/css2?family=Roboto&display=swap"
		rel="stylesheet"
	/>
</head>
```

Make sure to add both of the `<link/>` tag.

But this doesn't solve our problem just yet. We're preloading a stylesheet, but that stylesheet also imports fonts. We have to preload those as well.

If you visit `https://fonts.googleapis.com/css2?family=Roboto&display=swap` (the stylesheet location), you'll see a list of font-face declaration: 

```css
/* latin */
@font-face {
  font-family: 'Roboto';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(https://fonts.gstatic.com/s/roboto/v30/KFOmCnqEu92Fr1Mu4mxKKTU1Kg.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
```

That url inside `url(https://fonts.gstatic.com/s/roboto/v30/KFOmCnqEu92Fr1Mu4mxKKTU1Kg.woff2)` is the actual font and we can preload those as well:

```html
<head>
	  <!-- previous stuff -->
	 <link
		  rel="preload"
		 href="https://fonts.gstatic.com/s/roboto/v30/KFOmCnqEu92Fr1Mu4mxKKTU1Kg.woff2"
		 crossorigin
		 as="font"
		 type="font/woff2"
	/>
</head>
```

You only have to do this for `@font-face` with a `/* latin */` or `/* latin-ext */` comment since those are the font files for the English alphabet.

This won't be perfect but it should work 95% of the time.

Cheers!
04 berufliches Vorwärtskommen: Empfehlungen zum Vorwärtskommen
Tags: discuss, austausch, motivation, career
Published: 2023-03-22 08:19:37

Moin Moin,

Empfehlungen für die eigene Karriere ( berufliches Vorwärtskommen ). Falls du welche suchst oder auch welche geben möchtest bist du hier richtig.
Stellen wir uns folgendes vor:

> Angenommen ein guter Freund von dir, ein Software-Entwickler, möchte sich beruflich Weiterentwickeln. Welche Ratschläge würdest du ihm geben ?

Meine Empfehlung wäre Fortbildung, Fortbildung, Fortbildung. Das ist zumindest das Erste was mir einfällt. Die Stärken weiter ausbauen. Den eigenen Interessen nachgehen.
Das Zweite, was jedoch der Fortbildung eine Richtung gibt:

> Warum bist du Software-Entwickler geworden ?

Was treibt dich an, was ist dein „warum“.
Sobald das klar ist, ist auch klar was der nächste Schritt ist.

Beste Grüße,
Mustafa
Software Engineering
Tags: programming, react, flutter, webdev
Published: 2023-03-22 08:18:31

Software engineering is an ever-evolving field that is at the forefront of innovation in today's technology-driven world. It is a discipline that combines computer science principles with engineering practices to design, develop, and maintain high-quality software systems that meet the needs of users and businesses.


The impact of software engineering on our daily lives cannot be overstated. From the applications we use on our smartphones to the complex systems that run our financial institutions, software engineering has transformed the way we interact with technology and each other.


However, software engineering is not without its challenges. As the complexity of software systems increases, so too does the need for skilled software engineers who can design, develop, and maintain these systems effectively. The demand for skilled software engineers continues to rise, and the profession has become one of the most sought-after in the tech industry.


To be a successful software engineer, one must possess a combination of technical skills, problem-solving abilities, and creativity. Software engineers must be proficient in programming languages, software development tools, and development methodologies. They must also be able to work collaboratively with other members of their team and communicate complex technical concepts to non-technical stakeholders.


The importance of software engineering in today's world cannot be overstated. Software engineers are the driving force behind the development of innovative technologies that are transforming the way we live, work, and play. As the field continues to evolve, it is essential that we continue to invest in the education and training of future software engineers to ensure that we have the talent and skills needed to meet the challenges of the future.


In conclusion, software engineering is a powerful force that is shaping the future of technology and the world around us. It is a discipline that demands a combination of technical expertise, problem-solving skills, and creativity, and offers endless opportunities for innovation and growth. Whether you are a seasoned software engineer or just starting your journey in the field, there has never been a more exciting time to be a part of this dynamic and rewarding profession.
Swift Access Modifiers
Tags: swift, ios, xcod, accessmodifier
Published: 2023-03-22 08:07:05

Access modifiers are the identifiers which let us control the access level of class/struct/variable or methods.

In swift there are following Access Modifiers - 
**1. internal** - This is the default one. When don't mention any then this is the default type of access the class/struct etc get. 
In this one entities can be access and inherited within the target.

`Access level - accessible & inheritable within target`

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rumw31rlfwa1zw1ncy4b.png)

**2. private** - With this one entities are only accessible within class scope and, when accessed out of class then will give error.

`Access level - within enclosing declaration`

Example - In below screenshot , the property `osName` is inaccessible due to private access. 

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2h3yrs7dsc3isb1p0le0.png)

**3. fileprivate** - Just as the name explains, the entities are accessible within enclosing declaration and within same file  i.e in which it is declared.

`Access level - within enclosing declaration & within same file`

_Example 1_ - In below screenshot, the property `osName` is accessible out of its class scope because those classes are created in same file.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/a6720n577oys8gh9ybad.png)

_Example 2_ - In below screenshot, the property `osName` is inaccessible because the class accessing it is not in the same file in which osName was created. Hence, causes error.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xo0xqiyukppf7eivk06u.png)

**4. public** - This makes the entity accessible among other targets also however, they can't be inherited in the other targets.

`Access level - accessible in other targets but not inheritable out of self target`

_Example 1 - _
Target 1 -> class `ViewController`
Target 2 > class `NRDropDownHelper`

NRDropDownHelper is inaccessible in Target 1 (`ViewController` class) due to it's default internal level. Hence, causes error.

_Example 2 - _

After changing the class access to public 
1. It becomes accessible in ViewController
2. Yet can't be inherited outside target hence causes error.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/syvvwkrnjl4986stlman.png)

**5. open** - This is the highest level of access in swift. With this entities are accessible and inheritable in outside target as well.

`Access level - accessible and inheritable in other targets as well`

_example_ class `NRDropDownHelper` is access and is also inherited in class `customHelper`.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wcxcu6kn5sr866nxochk.png)
useMemeffect
Tags: react, useeffect, usememo, hook
Published: 2023-03-22 07:53:39

If you want to avoid unnecessary re-renders of your component when only some of the dependencies change, you can use the _useMemo_ hook to **memoize** the values that are derived from the dependencies. This way, the values will only be re-computed when the dependencies they depend on change.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ngrq34kpgn0x78p11owj.png)

In the above example, we're using useMemo to compute two derived values based on the dependencies. We then pass these derived values as dependencies to the useEffect hook. This means that the useEffect hook will only re-run when the derived values actually change, not when any of the original dependencies change but the derived values remain the same.

By using useMemo in this way, you can avoid unnecessary re-renders of your component and ensure that it only re-renders when it actually needs to.
Odd Even Number Checker using JavaScript (https://youtu.be/4YhYZooNohE)
Tags: javascript, developer, programmer
Published: 2023-03-22 07:43:22

---
title: Odd Even Number Checker using JavaScript (https://youtu.be/4YhYZooNohE)
published: true
description:  https://youtu.be/4YhYZooNohE
tags: JavaScript, Developer, Programmer 
# cover_image: https://direct_url_to_image.jpg
# Use a ratio of 100:42 for best results.
# published_at: 2023-03-22 07:41 +0000
---
Benefits of integrating your CRM and ERP Systems
Tags: crm, customer, discuss, api
Published: 2023-03-22 07:38:54

Integrating [CRM and ERP](https://www.databeys.com/) systems can have a number of benefits for your business, including: 

• Simplified Data Management: Integration of CRM and ERP systems eliminates the need for manual data entry and helps maintain data consistency across both systems. This can save time, reduce errors, and increase efficiency. 
• Better customer insights: By integrating your CRM and ERP systems, you can gain a more complete view of your customers and their interactions with your business. This can help you improve customer service, increase sales, and better target your marketing efforts. 
• Improved Sales Forecasting: Integration of CRM and ERP systems can help you forecast sales more accurately by giving you real-time visibility into your inventory levels, order history, and customer data. 
• Increase productivity: By automating tasks like data entry and reporting, integrating CRM and ERP systems can help increase productivity and free up employee time for more important tasks. 
• Cost savings: Integrating CRM and ERP systems can help you save money by reducing the need for redundant data entry, streamlining processes, and improving efficiency. 
  Overall, integrating CRM and ERP systems can help you improve your business processes, increase efficiency, and gain a better understanding of your customers, which leads to better customer service and increased sales. 
Read More: [Benefits Of Integrating Your CRM And ERP Systems](https://www.databeys.com/blog/benefits-of-integrating-your-crm-and-erp/)